Skip to content

Run Update library and Create PR #486

Run Update library and Create PR

Run Update library and Create PR #486

name: Run Update library and Create PR
on:
schedule:
- cron: '0 0 * * *'
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout Repository
uses: actions/checkout@v4
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: '18.x'
- name: Install Dependencies
run: yarn install
- name: Run Script and Commit Changes
run: ./dev/scripts/update-library.sh
- name: Create Pull Request
id: create_pr
uses: peter-evans/create-pull-request@v5
with:
token: ${{ secrets.GITHUB_TOKEN }}
branch: 'feat-bump-rpc-methods-${{ env.VERSION_TAG }}'
author: ${{ github.actor }} <${{ github.actor }}@users.noreply.github.com>
add-paths: |
package.json
src/rpc
commit-message: 'feat: update rpc methods with bitcoin core ${{ env.VERSION_TAG }}'
title: 'feat: update rpc methods with bitcoin core ${{ env.VERSION_TAG }}'
body: |
This PR updates rpc methods in src/rpc folder and the package version to ${{ env.VERSION_TAG }}.
labels: auto-merge
- name: Squash and merge Pull Request
uses: peter-evans/enable-pull-request-automerge@v3
with:
pull-request-number: ${{ steps.create_pr.outputs.pull-request-number }}
merge-method: squash
- name: Wait for Changes to be Merged
run: sleep 20s
tag:
needs: build
runs-on: ubuntu-latest
steps:
- name: Wait for Changes to be Pulled
run: sleep 10s
- name: Checkout Repository
uses: actions/checkout@v4
with:
ref: main
token: ${{ secrets.GH_TOKEN_JP }}
- name: Create Tag
run: |
TAG_NAME=$(node -p "require('./package.json').version")
git tag "v$TAG_NAME"
git push origin "v$TAG_NAME"