safe-repo

safe-repo is a skill for Claude Code from helderberto/agent-skills. It costs 83 tokens per session (482 once invoked), scanned A, original, MIT.

A repository security check for credentials, API keys, company information, personal data, and sensitive files. It can scan the full tracked repository or only current changes.

In plain words
What is it for?
Use it for periodic repository audits or before committing changes, with a focused mode for staged and unstaged files.
Why use it?
It helps catch information that should not be committed, including secrets removed from files but still present in Git history.

Skill for Claude Code

Written for Claude Code: argument-hint in frontmatter.

Part of the hb plugin — 38 skills, 6 agents shipped together

Good fit Use it for periodic repository audits or before committing changes, with a focused mode for staged and unstaged files.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/helderberto/agent-skills/safe-repo
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add helderberto/agent-skills --skill safe-repo
Clone the repo
git clone --depth 1 https://github.com/helderberto/agent-skills

Made for: Claude Code.

Or install hb, the plugin that ships this one along with the rest of its 38 skills, 6 agents.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for safe-repo

README.md
[![agentmods](https://agentmods.dev/badge/skills/helderberto/agent-skills/safe-repo/github.svg)](https://agentmods.dev/skills/helderberto/agent-skills/safe-repo)
Your own site
<a href="https://agentmods.dev/skills/helderberto/agent-skills/safe-repo"><img src="https://agentmods.dev/badge/skills/helderberto/agent-skills/safe-repo/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for safe-repo

Your own site · 80×15
<a href="https://agentmods.dev/skills/helderberto/agent-skills/safe-repo"><img src="https://agentmods.dev/badge/skills/helderberto/agent-skills/safe-repo.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 83 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 482 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00083 $0.00482
Opus 5 $0.00042 $0.00241
Sonnet 5 $0.00017 $0.00096
Haiku 4.5 $0.00008 $0.00048

Measured 10d ago against content hash 7a08eed854de, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-09, from the pricing page.

Security

Grade A, and why

safe-repo scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 10d ago.

The scan reads SKILL.md. This mod also ships 1 executable file (scripts/scan-secrets.sh), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/safe-repo/SKILL.md · 48 lines

What it actually says

Safe Repository Check

Context

Security audit for sensitive data in repository. Check for credentials, API keys, company-specific information, and PII.

Modes

  • Default (full-scan): scans all git-tracked files plus history. Use for periodic audits or first-time repo review.
  • --diff: scans only staged + unstaged changes (git diff + git diff --cached). Use before commit or when called from review / ship workflows. Fast, no false positives from pre-existing files.

Workflow

Default (full-scan)

  1. Run bash scripts/scan-secrets.sh to scan all tracked files for credential patterns (see references/patterns.md for full pattern list)
  2. Check for sensitive tracked files (.env, secrets)
  3. Analyze git history for removed secrets
  4. Review .gitignore for proper patterns
  5. Report findings (see assets/report-template.md)

--diff mode

  1. Compute changed files: git diff --name-only HEAD + git diff --name-only --cached
  2. Scan only those files against the credential patterns
  3. Skip history analysis (not relevant for in-flight changes)
  4. Report findings scoped to changed files only

Rules

  • Only check git-tracked files (git ls-files) - ignore local configs
  • Check current tracked files AND git history
  • Filter false positives: minified JS, node_modules, test fixtures, docs
  • Verify .gitignore covers sensitive patterns
  • Report tracked files with secrets and historical commits
  • Never output actual secret values in report

Error Handling

  • If git history scan is slow → limit to last 100 commits with git log --oneline -100
Files

What ships with it

3 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 10d ago First seen · 48 lines · 83 tokens per session scan A 7a08eed854de

Subscribe to this mod's changes

safe-repo is a skill published in the GitHub repository helderberto/agent-skills (14 stars, last pushed 8d ago), licensed MIT. It adds 83 tokens to every session and 482 once invoked, about $0.0004 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

case-interview-practice

Interactive consulting case interview practice with structured frameworks, feedback mechanisms, and progressive difficulty. Use when preparing for management consulting interviews, case competitions, or business problem-solving exercises.

travisjneuman/.claude · 39 tokens

finance

Financial analysis expertise for financial modeling (DCF, LBO, M&A), valuation, financial statement analysis, capital allocation, treasury management, and corporate finance decisions. Use when building financial models, analyzing statements, or making investment decisions.

travisjneuman/.claude · 48 tokens

i18n-localization

Internationalization and localization for global applications. Use when adding multi-language support, handling regional formats, or preparing apps for global markets.

travisjneuman/.claude · 32 tokens

content-repurposer

Adapt content across platforms with tone/format shifting — blog to social, long to short, text to visual outline. Use when repurposing content for different channels, audiences, or formats.

travisjneuman/.claude · 43 tokens

electron-desktop

Desktop application development with Electron for Windows, macOS, and Linux. Use when building cross-platform desktop apps, implementing native OS features, or packaging web apps for desktop.

travisjneuman/.claude · 38 tokens

impact-report-writer

Nonprofit/NGO impact report generation with data visualization suggestions, outcome metrics, narrative structure, and program data presentation. Use when writing impact reports, annual reports, or program evaluation summaries.

travisjneuman/.claude · 43 tokens