Make a discog backup #159
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: Make a discog backup | |
on: | |
schedule: | |
- cron: '30 18 * * *' | |
jobs: | |
go-backup: | |
name: Setup | |
runs-on: ubuntu-latest | |
if: github.ref == 'refs/heads/main' | |
env: | |
USER: ${{ secrets.USER }} | |
TOKEN: ${{ secrets.TOKEN }} | |
steps: | |
- | |
name: Check out | |
uses: actions/checkout@v3 | |
- | |
name: Go backup | |
run: | | |
go run main.go > discog.json | |
- | |
name: Upload backup | |
uses: actions/upload-artifact@v3 | |
with: | |
name: discog_collections | |
path: discog.json |