.github/workflows/backup_workflow.yml #138
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
on: | |
schedule: | |
- cron: '0 23 * * *' | |
jobs: | |
pull-changes: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v2 | |
- name: Pull changes from main branch | |
run: | | |
git checkout -B backup-branch | |
git pull origin main | |
git push origin backup-branch -f | |