SonarCloud Triage
Repeatable triage of SonarCloud findings for sunholo-data_ailang via the Web API.
Everything the web UI does for triage is available through the API, and most of it
is faster from the shell.
Prerequisites
SONAR_PAT— personal admin token, exported in~/.zshenv. Get one at
<https://sonarcloud.io/account/security>. Read-only scripts (gate_status,
fetch_*) don't need it; mutating scripts (mark_*, set_new_code) do.
- Optional overrides:
SONAR_PROJECT(defaultsunholo-data_ailang),
SONAR_ORG (default sunholo-data), SONAR_HOST (default https://sonarcloud.io).
Standard triage workflow
1. scripts/gate_status.sh → see which conditions fail and on what metric
2. scripts/fetch_hotspots.sh → group TO_REVIEW hotspots by rule + directory
3. For each rule listed in resources/known_fp_rules.md:
scripts/mark_safe.sh RULE_KEY "<comment from known_fp_rules.md>"
4. scripts/fetch_issues.sh → list remaining BLOCKER/CRITICAL bugs + vulns
5. For each issue that matches a known-FP row:
scripts/mark_fp.sh ISSUE_KEY "<comment from known_fp_rules.md>"
6. scripts/set_new_code.sh 30 → rolling 30-day New Code window (if not already)
7. scripts/gate_status.sh → confirm conditions moved