Commit e400e7e
ci: scope GITGUARDIAN_API_KEY to ggshield-action step only
Per Copilot review feedback on YouTubeMusicPS#21: the previous job-level
env exposed the full secret value to every step in the job (including
actions/checkout and any future additions), even though only the
ggshield-action step needs it.
Switches to a boolean-gate pattern: job-level env exposes only
GGSHIELD_ENABLED (a "true"/"false" string indicating whether the secret
is set), and the actual GITGUARDIAN_API_KEY value is scoped via
step-level env on the ggshield-action invocation. Behavior unchanged
when the secret is set; better defense-in-depth against future steps
inheriting the secret unintentionally.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>1 parent cc3d14e commit e400e7e
1 file changed
Lines changed: 9 additions & 5 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
9 | 9 | | |
10 | 10 | | |
11 | 11 | | |
12 | | - | |
13 | | - | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
14 | 16 | | |
15 | 17 | | |
16 | | - | |
| 18 | + | |
17 | 19 | | |
18 | 20 | | |
19 | | - | |
| 21 | + | |
20 | 22 | | |
21 | 23 | | |
22 | 24 | | |
23 | | - | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
0 commit comments