Update v8CTF Challenges #32
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 v8CTF Challenges | |
| on: | |
| schedule: | |
| # This schedule runs at 00:00 UTC every Wednesday. | |
| - cron: '0 0 * * 3' | |
| workflow_dispatch: # Temporary to re-trigger the failed workflow run | |
| jobs: | |
| update-challenges: | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: write | |
| steps: | |
| - name: Check out the repository | |
| uses: actions/checkout@v4 | |
| - name: Install dependencies | |
| run: | | |
| sudo apt-get update | |
| sudo apt-get install -y xxd | |
| - name: Run the update script | |
| run: | | |
| ./v8ctf/scripts/update_challenges.sh | |
| - name: Commit and push changes | |
| run: | | |
| git config --global user.name 'v8CTF github action' | |
| git config --global user.email 'sroettger@google.com' | |
| # Check if there are any changes to commit | |
| if [[ -z $(git status --porcelain) ]]; then | |
| echo "No changes to commit" | |
| exit 0 | |
| fi | |
| git add v8ctf | |
| git commit -am "[v8ctf] Update v8CTF challenges" | |
| git push |