skills/semgrep-scan/SKILL.md
Scan changed files with Semgrep for security and correctness issues. Use when verifying code before committing, reviewing implementation security, or running pre-commit quality gates.
npx skillsauth add sheurich/agent-skills semgrep-scanInstall 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.
Security and correctness gate on changed files.
semgrep_scan_with_custom_rule MCP tool)uvx semgrep scan --config auto . directly)semgrep_scan_supply_chain MCP tool)git diff --name-only HEAD --diff-filter=ACMR
Initial commit (no HEAD): git diff --cached --name-only --diff-filter=ACMR
Stop if no changed files.
uvx semgrep scan --config auto --json --quiet <files...>
If .semgrep/rules/ or .semgrep.yml exists at the repo root, add
--config .semgrep/ to include project-specific rules.
Parse results[] from the JSON output.
| Field | Location |
|-------|----------|
| Rule ID | results[].check_id |
| Severity | results[].extra.severity |
| Message | results[].extra.message |
| File + line | results[].path, results[].start.line |
| Fix suggestion | results[].extra.fix (when present) |
| CWE | results[].extra.metadata.cwe |
| Severity | Action |
|----------|--------|
| ERROR | Fix before committing — these are real vulnerabilities |
| WARNING | Review and fix, or suppress with # nosemgrep: <rule-id> if false positive |
| INFO | Note for awareness — do not block commit |
Re-scan after fixes until clean. Report finding count or "Semgrep scan clean — no findings on N files."
tools
Delegate tasks to Swival for self-reviewed code changes, sandboxed execution, secret-safe operations, cached analysis, local-model inference, and A2A agent serving or client usage. Use when a task benefits from automated review loops against acceptance criteria, filesystem sandboxing, credential encryption, LLM response caching, or orchestrating a network of A2A agents.
tools
Write and refine agent skills. Use when generating skills from docs, extracting from sessions, designing tool interfaces, managing lifecycle, or writing for dual-harness patterns.
development
Structured readiness assessment before proceeding to the next environment or phase. Use when asked for a readiness review, go/no-go assessment, or deployment review.
development
Maintainer-only workflow for handling GitHub Secret Scanning alerts on OpenClaw. Use when Codex needs to triage, redact, clean up, and resolve secret leakage found in issue comments, issue bodies, PR comments, or other GitHub content.