NPP Daily reports #804
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: NPP Daily reports | |
| on: | |
| workflow_dispatch: {} | |
| schedule: | |
| - cron: '36 16 * * *' # IST 10PM+ | |
| jobs: | |
| download-reports: | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 10 | |
| permissions: | |
| contents: write | |
| steps: | |
| - name: Check out this repo | |
| uses: actions/checkout@v4 | |
| - name: Fetch latest data | |
| run: python3 download_reports.py | |
| - name: Commit and push if it changed | |
| run: |- | |
| git config user.name "Automated" | |
| git config user.email "actions@users.noreply.github.com" | |
| git add -A | |
| timestamp=$(date -u) | |
| git commit -m "Latest reports: ${timestamp}" || exit 0 | |
| git push | |
| - name: install dependencies | |
| run: pip install -r requirements.txt | |
| - name: Fetch latest data | |
| run: python3 parse_reports.py | |
| - name: Commit and push if it changed | |
| run: |- | |
| git config user.name "Automated" | |
| git config user.email "actions@users.noreply.github.com" | |
| git add -A | |
| timestamp=$(date -u) | |
| git commit -m "Parsed data: ${timestamp}" || exit 0 | |
| git push |