markmikkelsen is updating export_fig #5
This file contains hidden or 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 export_fig | |
| run-name: ${{ github.actor }} is updating export_fig | |
| on: [push] | |
| jobs: | |
| update-export_fig: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout gannet repo | |
| uses: actions/checkout@v3 | |
| - name: Checkout export_fig repo | |
| uses: actions/checkout@v3 | |
| with: | |
| repository: altmany/export_fig | |
| path: export_fig_tmp/ | |
| - name: Copy files from separate repo to current repo | |
| run: | | |
| rsync -av --exclude '.git' export_fig_tmp/ export_fig/ | |
| rm -rf export_fig_tmp/ | |
| - name: Commit and push changes | |
| run: | | |
| git config --global user.name "${GITHUB_ACTOR}" | |
| git config --global user.email "${GITHUB_ACTOR}@users.noreply.github.com" | |
| git add . | |
| git diff-index --quiet HEAD || git commit -m "Sync with altmany/export_fig repo" | |
| git push |