Skip to content

Pull Google Calendar Events #542

Pull Google Calendar Events

Pull Google Calendar Events #542

name: Pull Google Calendar Events
on:
schedule:
- cron: '0 14 * * *' # runs every day at midnight
push:
branches: ["google-api-backend"]
workflow_dispatch:
jobs:
pull_events:
runs-on: ubuntu-latest
steps:
- name: checkout repo content
uses: actions/checkout@v3 # checkout the repository content to github runner.
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: '3.x'
- name: Install Dependencies
run: pip install -r requirements.txt
- name: Run Git Pull
run: "git pull --rebase"
- name: Run Script
env:
API_KEY: ${{ secrets.GOOGLE_CALENDAR_API_KEY }}
run: python pull-events.py
- name: Commit Files
uses: stefanzweifel/git-auto-commit-action@v4
with:
commit_message: Update google calendar data