Skip to content

Daily Data Collection #24

Daily Data Collection

Daily Data Collection #24

Workflow file for this run

# SPDX-FileCopyrightText: 2025 Joost van der Laan <[email protected]>
#
# SPDX-License-Identifier: AGPL-3.0-only
name: Daily Data Collection
on:
schedule:
# Run at 00:00 UTC every day
- cron: '0 0 * * *'
# Allow manual trigger
workflow_dispatch:
env:
CARGO_TERM_COLOR: always
# Add your environment variables here
FINANCIALMODELINGPREP_API_KEY: ${{ secrets.FINANCIALMODELINGPREP_API_KEY }}
POLYGON_API_KEY: ${{ secrets.POLYGON_API_KEY }}
jobs:
collect-data:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: DeterminateSystems/nix-installer-action@main
- uses: DeterminateSystems/magic-nix-cache-action@main
- uses: DeterminateSystems/flake-checker-action@main
- name: Build and run data collection
run: |
nix \
--extra-experimental-features "nix-command flakes" \
develop \
--command bash -c "cargo build --release && ./target/release/top200-rs export-combined"
- name: Upload CSV artifact
uses: actions/upload-artifact@v4
with:
name: market-data-${{ github.run_number }}
path: |
output/*.csv
retention-days: 90