Get Debates #23
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: Get Debates | |
on: | |
workflow_dispatch: | |
schedule: | |
# run once every day at midnight | |
- cron: '0 0 * * *' | |
jobs: | |
process-debates: | |
defaults: | |
run: | |
shell: bash -leo pipefail {0} | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
with: | |
token: ${{ secrets.DEPLOY_TOKEN }} | |
- uses: mamba-org/setup-micromamba@v1 | |
name: install deps | |
with: | |
micromamba-version: '1.3.1-0' | |
environment-file: environment-simple.yml | |
init-shell: >- | |
bash | |
cache-environment: true | |
post-cleanup: 'all' | |
- name: Setup Rclone | |
uses: AnimMouse/setup-rclone@v1 | |
with: | |
rclone_config: ${{ secrets.RCLONE_CONFIG }} | |
- name: Extract gcloud config from rclone config | |
run: echo "${{ secrets.RCLONE_CONFIG }}" | python parse_rclone_conf.py > gcloud.json | |
- name: Process Debates | |
env: | |
CLIENT_SECRETS_FILE: gcloud.json | |
run: python process_debates.py --skip-transcription | |
- name: Commit and Push Changes | |
uses: EndBug/add-and-commit@v7 | |
with: | |
message: 'Update debates data' | |
add: 'public/debates/ src/debates.json' | |