name: Regenerate profile stats cards # Runs daily; recompute stats cards via the repo's own generate_stats.py # (stdlib-only, no external service) and commit them to this repo, where # README.md embeds them. on: schedule: - cron: "30 4 * * *" workflow_dispatch: {} jobs: stats: runs-on: ubuntu-latest steps: - name: Checkout profile repo uses: actions/checkout@v4 - name: Generate stats images env: GIT_URL: https://git.turbo-data.com USER: doctasmooth # Token with "read:user" + "read:repository" scopes; include private # repos in the stats. Leave empty to only use public data. ACCESS_TOKEN: ${{ secrets.STATS_READ_TOKEN }} run: python3 generate_stats.py - name: Commit updated cards run: | git config user.name "stats-bot" git config user.email "stats-bot@users.noreply.git.turbo-data.com" git add stats/ if [[ -n "$(git status --porcelain stats/)" ]]; then git commit -m "chore: regenerate profile stats cards" git push https://${{ secrets.STATS_COMMIT_TOKEN }}@git.turbo-data.com/doctasmooth/.profile.git HEAD:main else echo "Stats unchanged, nothing to commit" fi