Update config files #79
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Update chains file | |
on: | |
workflow_dispatch: | |
inputs: | |
file_path: | |
description: 'Which version of chains.json will be used?' | |
required: true | |
type: string | |
default: v1 | |
schedule: | |
- cron: '0 8 * * 1' | |
jobs: | |
update-chains-file: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: Set spektr config version | |
run: | | |
if [ "${{ github.event_name }}" = "workflow_dispatch" ] | |
then | |
echo "CHAINS_VERSION=${{ github.event.inputs.file_path }}" >> $GITHUB_ENV | |
else | |
echo "CHAINS_VERSION=${{ secrets.SPEKTR_CONFIG_VERSION }}" >> $GITHUB_ENV | |
fi | |
- name: ⚙️ Install dependencies | |
uses: ./.github/workflows/install-pnpm | |
- name: 📝 Update chains file | |
run: pnpm update:chains-file | |
- name: ➡️ Make pull request | |
uses: ./.github/workflows/make-pull-request | |
with: | |
commit_path: src/renderer/shared/config/chains/*.json | |
commit_message: "ci: chains.json file" | |
pr_title: "Update chains.json file" | |
branch_name: update-chains-file | |
github_token: ${{ secrets.GITHUB_TOKEN }} |