Main actions #779
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: Main actions | |
on: | |
workflow_dispatch: | |
schedule: | |
- cron: "0 7 * * *" | |
jobs: | |
pull-redfin: | |
name: Summarize Redfin | |
runs-on: "ubuntu-latest" | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: conda-incubator/setup-miniconda@v2 | |
with: | |
python-version: 3.9 | |
mamba-version: "*" | |
channels: conda-forge,defaults | |
channel-priority: true | |
activate-environment: yellowtail | |
environment-file: envs/env.yml | |
miniforge-variant: Mambaforge | |
use-mamba: true | |
- name: Download Redfin snapshot | |
shell: bash -l {0} | |
run: | | |
conda info | |
conda list | |
conda config --show-sources | |
conda config --show | |
python -m pip install -e . | |
python scripts/pull_redfin.py | |
- name: Summarize Redfin snapshot | |
shell: bash -l {0} | |
run: | | |
python scripts/summarize.py --incremental | |
- name: Commit files | |
shell: bash | |
run: | | |
git config --local user.email "41898282+github-actions[bot]@users.noreply.github.com" | |
git config --local user.name "github-actions[bot]" | |
git add output/listings.csv.gz | |
git add output/per_day_summary.csv | |
git commit --allow-empty -m "Update output (GHA)" | |
- name: Push changes | |
uses: ad-m/github-push-action@v0.6.0 | |
with: | |
github_token: ${{ secrets.GITHUB_TOKEN }} | |
branch: main | |