Update ICS Calendar #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: Update ICS Calendar | |
on: | |
schedule: | |
- cron: "0 0 * * *" # Runs at midnight every day | |
workflow_dispatch: # Allows manual triggering of the workflow | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
- name: Set up Ruby | |
uses: ruby/setup-ruby@v1 | |
with: | |
bundler-cache: true | |
- name: Run rake task to generate ICS | |
run: bundle exec rake esport_ics:generate:all | |
env: | |
PANDASCORE_API_TOKEN: ${{ secrets.PANDASCORE_API_TOKEN }} | |
- name: Commit and push changes | |
run: | | |
git config user.name github-actions | |
git config user.email [email protected] | |
git add ics/ | |
git commit -m 'Update ICS files' | |
git push | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |