chore: update ci #8
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: Template Cleanup | |
on: | |
push: | |
branches: | |
- main | |
jobs: | |
# Run a cleaning process only if the workflow is triggered by the non-"Miki-Captain" repository. | |
template-cleanup: | |
name: Template Cleanup | |
runs-on: ubuntu-latest | |
if: github.repository != 'yjl9903/Miki-Captain' | |
permissions: | |
contents: write | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Clean data | |
run: | | |
rm -rf data/ | |
rm .github/workflows/cleanup.yml | |
- name: Commit and push | |
run: | | |
git add . | |
git config user.name 'github-actions[bot]' | |
git config user.email 'github-actions[bot]@users.noreply.github.com' | |
git commit -m "chore: cleanup old data" | |
git push | |