Skip to content

Commit

Permalink
Attempt to store ICS
Browse files Browse the repository at this point in the history
  • Loading branch information
hugoabernier committed Apr 13, 2024
1 parent 0dee07e commit b599c6c
Showing 1 changed file with 26 additions and 0 deletions.
26 changes: 26 additions & 0 deletions .github/workflows/update-ics.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: Download ICS File

on:
schedule:
- cron: '0 * * * *' # Optional: Runs every hour
workflow_dispatch: # Allows manual trigger

jobs:
download-and-save-ics:
runs-on: ubuntu-latest

steps:
- name: Checkout repository
uses: actions/checkout@v2

- name: Download ICS file
run: |
mkdir -p ./ical # Ensure the ical directory exists
curl -o ./ical/calendar.ics ${{ secrets.ICS_URL }}
- name: Commit and push if there are changes
run: |
git config --local user.email "[email protected]"
git config --local user.name "GitHub Action"
git add ./ical/
git diff --quiet && git diff --staged --quiet || (git commit -m "Update ICS file" && git push)

0 comments on commit b599c6c

Please sign in to comment.