Files
poli0981andClaude Opus 5.5 988e4f4ce6 ci: pin third-party actions, install without lifecycle scripts, hash Python deps
SonarCloud's GitHub Actions and shell findings, all supply-chain hardening
for jobs that hold a write token (and, in the release workflows, the
signing keys):

- The six third-party actions in release-desktop.yml and release-android.yml
  are pinned to the commit their major tag points at today, with the version
  in a comment for Dependabot. dtolnay/rust-toolchain is pinned to a master
  commit and given `toolchain: stable`: its `stable` branch is regenerated
  on top of master, so a commit of it can vanish.
- Every `npm ci` is `npm ci --ignore-scripts`. Only fsevents, workerd and
  wrangler's esbuild have install scripts; the last two find their binary in
  their optional platform package without them, and fsevents is only file
  watching. `npx` is gone from the workflows (`npm run cf:check`,
  `npm test -- <file>`).
- requirements.txt pins every runtime package, transitive ones included
  (certifi, charset-normalizer, idna), with the sha256 of every file on
  PyPI; every install is `--require-hashes --only-binary :all:`. The new
  requirements-test.txt holds pytest the same way. python-tests.yml runs the
  data jobs' exact install line first, so a Dependabot bump is proven before
  a data job meets it.
- `[[ ]]` instead of `[ ]` in the bash wrappers.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-19 09:31:40 +07:00

13 lines
540 B
Bash
Executable File

#!/bin/bash
set -euo pipefail
pip install --quiet --require-hashes --only-binary :all: -r requirements.txt
# PEAKS_ALL is the manual run's "backfill" box: "true" asks SteamCharts about
# every game (~4 h) instead of today's thirtieth. A scheduled run leaves it
# empty, and an unticked box sends "false" - neither may pass --all.
args=()
if [[ "${PEAKS_ALL:-}" == "true" ]]; then
args+=(--all)
fi
python scripts/refresh_peaks.py ${args[@]+"${args[@]}"}
bash "$(dirname "$0")/commit_push.sh" "Refresh all-time peaks [$(date +'%Y-%m-%d')]"