skills/SecretScan/SKILL.md
Commit-time secret scanning with gitleaks — prevent credentials from entering git history. USE WHEN scanning for leaked secrets, setting up pre-commit hooks, or auditing repositories for credentials.
npx skillsauth add n4m3z/forge-core SecretScanInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Prevent secrets from entering git history using gitleaks.
brew install gitleaks
gitleaks detect --source . --no-git
gitleaks detect --source .
For pre-commit checks where only staged content matters:
gitleaks protect --source . --staged --no-banner
gitleaks protect (vs detect) operates on the working-tree diff and is faster than a full scan when integrated into a pre-commit flow.
If the repo has historical secrets that have been rotated, create a baseline so future scans only flag new leaks:
gitleaks detect --source . --report-path .gitleaks-baseline.json
gitleaks detect --source . --baseline-path .gitleaks-baseline.json
Add to .pre-commit-config.yaml:
- id: gitleaks
name: gitleaks
entry: gitleaks detect --no-banner --no-git -s .
language: system
pass_filenames: false
Config file at the project root for allowlists. Use path exclusions, not fingerprints — fingerprints break when line numbers shift:
[allowlist]
paths = [
"evals/baselines/.*",
"tests/fixtures/.*",
]
Present findings grouped by severity, never echoing the secret value:
## Secret Scan: <repo>
**Mode**: working tree | staged | history
**Findings**: <count>
### Critical (must fix before merge)
- <file>:<line> <rule-id> — short description
### Allowlisted (known safe)
- <file>:<line> <rule-id> — reason
### Recommendation
<fix | baseline | allowlist guidance>
.env, credentials, or API keys — even to private reposbrew install gitleaks) and stop — do not partially scan--no-verify--no-verify for historical secrets that have already been rotated.env file that is not in .gitignore as a configuration issuedevelopment
Reactive correction and root-cause fix. USE WHEN something went wrong, user is frustrated, demands a correction, says wtf, what the hell, why did you, that's wrong, this is broken, no not that, stop. Executes the immediate fix, then hunts the upstream artifact that caused it and creates a corrective change.
development
Decompose a research question into sub-queries, spawn parallel WebResearcher agents per angle, synthesize findings with citations and explicit confidence. USE WHEN the user asks to research, investigate, look online, look up, dig into, find sources, gather evidence, or survey what's known about a topic. Single-pass; for multi-round adversarial research use ResearchCouncil in forge-council.
tools
Author project documentation that future humans (and AI sessions) actually read. Covers TLDRs for tools, READMEs, runbooks, journals. USE WHEN write documentation, create tldr, tool one-pager, document a cli, write readme, runbook, journal entry, capture knowledge about a tool, distill a session into reusable notes.
development
Review your own staged changes via a code-review TUI before triggering a commit. USE WHEN about to commit, walking through your own staged diff, self-reviewing before approval, tuicr, revdiff, git diff cached.