Skip to content

Commit

Permalink
Add auto-update gh action
Browse files Browse the repository at this point in the history
  • Loading branch information
rkalis committed Jan 25, 2023
1 parent 2d7138a commit 035be83
Showing 1 changed file with 30 additions and 0 deletions.
30 changes: 30 additions & 0 deletions .github/workflows/update.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
name: Update
on:
workflow_dispatch:
# Auto-update every week on midnight Monday
schedule:
- cron: '0 0 * * 1'
jobs:
update:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v2
with:
node-version: '12.x'
registry-url: 'https://registry.npmjs.org'
- name: Install dependencies
run: yarn
- name: Generate new files
run: yarn generate && yarn build
- name: Update version
run: yarn version --patch --no-git-tag-version
- name: Commit and push changes
uses: EndBug/add-and-commit@v9
with:
default_author: 'github_actions'
message: 'Update generated files'
- name: Publish to npm
run: yarn publish
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

0 comments on commit 035be83

Please sign in to comment.