Skip to content

Commit

Permalink
Updated workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
johc committed Mar 27, 2024
1 parent 0842d7a commit 5e6b241
Showing 1 changed file with 6 additions and 7 deletions.
13 changes: 6 additions & 7 deletions .github/workflows/fetch_data.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,18 +2,18 @@ name: Fetch MongoDB Data

on:
schedule:
- cron: '0 0 * * 0' # This sets it to run weekly on Sunday at midnight
workflow_dispatch: # Manual trigger
- cron: '0 0 * * 0' # Runs weekly on Sunday at midnight
workflow_dispatch:

jobs:
fetch_data:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Checkout master branch
uses: actions/checkout@v3

- name: Set up Python
uses: actions/setup-python@v2
uses: actions/setup-python@v4
with:
python-version: '3.x'

Expand All @@ -28,11 +28,10 @@ jobs:
run: |
python fetch_data.py
# Commit and Push changes
- name: Commit and Push changes
run: |
git config --local user.email "[email protected]"
git config --local user.name "GitHub Action"
git add -A
git commit -m "Update data files" || true
git push origin gh-pages
git push

0 comments on commit 5e6b241

Please sign in to comment.