agentleFS
Sagargupta16Sagargupta16/craftsmanship/skills/guard/SKILL.md

guard

Skill2 starsChanged 30 days agoMITView on GitHub

Use when making git operations, handling secrets, committing code, or dealing with credentials. Enforces git safety rules (no force-push to main, no amend of published commits), secret-handling discipline (never commit .env, use .env.example), and destructive-command caution.

  • Reads credentials
  • Deletes or force-pushes
  • Commits and pushes

61 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use unfreeze, setup-deploy and 10 more.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • ayudaySkill

    unfreeze

    Clear the freeze boundary set by /freeze, allowing edits to all directories again. Use when you want to widen edit scope without ending the session. Use when asked to "unfreeze", "unlock edits", "remove freeze", or "allow all edits".

    Also in 29 projects that use this

  • ayudaySkill

    setup-deploy

    Configure deployment settings for /land-and-deploy. Detects your deploy platform (Fly.io, Render, Vercel, Netlify, Heroku, GitHub Actions, custom), production URL, health check endpoints, and deploy status commands. Writes the configuration to CLAUDE.md so all future deploys are automatic. Use when: "setup deploy", "configure deployment", "set up land-and-deploy", "how do I deploy with gstack", "add deploy config".

    Also in 22 projects that use this

  • ShreyRaviSkill

    plan-tune

    Self-tuning question sensitivity + developer psychographic for gstack (v1: observational). Review which AskUserQuestion prompts fire across gstack skills, set per-question preferences (never-ask / always-ask / ask-only-for-one-way), inspect the dual-track profile (what you declared vs what your behavior suggests), and enable/disable question tuning. Conversational interface — no CLI syntax required.

    Also in 12 projects that use this

  • seek888Skill

    open-gstack-browser

    Launch GStack Browser — AI-controlled Chromium with the sidebar extension baked in. Opens a visible browser window where you can watch every action in real time. The sidebar shows a live activity feed and chat. Anti-bot stealth built in. Use when asked to "open gstack browser", "launch browser", "connect chrome", "open chrome", "real browser", "launch chrome", "side panel", or "control my browser". Voice triggers (speech-to-text aliases): "show me the browser".

    Also in 12 projects that use this

  • ShreyRaviSkill

    landing-report

    Read-only queue dashboard for workspace-aware ship. Shows which VERSION slots are currently claimed by open PRs, which sibling Conductor workspaces have WIP work likely to ship soon, and what slot /ship would pick next. No mutations — just a snapshot. Use when asked to "landing report", "what's in the queue", "show me open PRs", or "which version do I claim next". (gstack)

    Also in 11 projects that use this

  • Saqlain-811Skill

    ios-fix

    Autonomous iOS bug fixer. (gstack)

    Also in 6 projects that use this

  • +2 more from ShreyRavi

The file

We split this skill into the rules it gives an agent

4 rules. 0 are common, 3 are distinctive, and 1 is very specific to this project.

  • 0

    Common

    Most of the 50 edited versions we read keep these.

  • 3

    Distinctive

    This author's own choices. Worth a look.

  • 1

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Use git filter-repo or BFG to remove from history

    line 55
  2. Very specific:

    Check vulnerabilities before adding new packages (npm audit, pip-audit, cargo audit)

    line 83
  3. Distinctive:

    Prefer well-maintained packages with active security response

    line 84
  4. Distinctive:

    Before uploading: is this content sensitive?

    line 105

“Common” is measured: kept by at least 6 in 10 of the 50 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Safety Guardrails

Git Safety

RuleWhy
Never force push to main/masterDestroys team history, breaks CI
Never git reset --hard without explicit confirmationIrreversible data loss
Never amend published commitsCreates divergent history for collaborators
Never skip pre-commit hooks (--no-verify)Hooks catch real issues
Stage specific files by namegit add . risks committing secrets or binaries
Never commit .env, credentials, API keysSecrets in git history are permanent
Verify current branch before pushingAvoid pushing to wrong branch
Never force-push to someone else's branchOnly to your own fork branches

Destructive Commands

These commands need explicit user confirmation before running:

CommandRisk
rm -rfPermanent file deletion
git reset --hardDiscards uncommitted changes
git push --forceOverwrites remote history
git clean -fdxDeletes untracked files including gitignored
DROP TABLE / TRUNCATEIrreversible data loss
kill -9 on shared processesMay corrupt state
Modifying CI/CD pipelinesVisible to whole team

Secrets and Credentials

Never Commit

  • .env files, .env.* (except .env.example)
  • API keys, access tokens, bearer tokens
  • Passwords, connection strings with credentials
  • Private keys (.pem, .key, id_rsa)
  • OAuth client secrets
  • Cloud provider credentials (AWS, GCP, Azure)

Use Placeholders

.env.example with placeholder values is safe to commit:

DATABASE_URL=postgresql://user:password@localhost:5432/dbname
API_KEY=your-api-key-here
AWS_ACCESS_KEY_ID=AKIAIOSFODNN7EXAMPLE

If Real Credentials Are in Git History

  1. Rotate the credential immediately -- git history is permanent and public
  2. Use git filter-repo or BFG to remove from history
  3. Force-push cleaned history (coordinate with team)
  4. Audit access logs for suspicious use

Scan Before Committing

# Check staged changes for common secret patterns
git diff --cached | grep -iE 'api[_-]?key|secret|password|token|bearer' | grep -v example

# Tools
gitleaks detect --source=. --verbose
trufflehog git file://. --only-verified

Code Security Basics

RuleWhy
Validate user input at system boundariesPrevents injection attacks
Use parameterized queries, never string concatSQL injection
Sanitize data before rendering in templatesXSS
Use bcrypt/argon2 for password hashingMD5/SHA are broken for passwords
Set CORS origins from env, never wildcard in prodCross-origin attacks
HTTPS only, no mixed contentMITM attacks
Rate-limit authentication endpointsCredential stuffing / brute force

Dependency Safety

  • Check vulnerabilities before adding new packages (npm audit, pip-audit, cargo audit)
  • Prefer well-maintained packages with active security response
  • Pin dependency versions in lock files
  • Review package permissions (scripts, post-install hooks)
  • Watch for typosquatting: reqeusts vs requests, expresss vs express

Working with Shared Systems

Actions that affect others need confirmation:

  • Pushing code (affects CI, teammates)
  • Creating/closing/commenting on PRs or issues
  • Sending messages (Slack, email, GitHub)
  • Modifying shared infrastructure
  • Deploying to staging/production

Third-Party Uploads

Uploading content to external tools publishes it:

  • Pastebins, gists, diagram renderers
  • Cloud storage with sharable links
  • AI chatbots (data may be retained/trained on)

Before uploading: is this content sensitive? PII, internal architecture, credentials?

Anti-Patterns

Anti-PatternProblemDo Instead
git add .Accidentally stages secrets, binariesStage specific files by name
--no-verify to skip hooksBypasses real safety checksFix the hook failure, or ask why it's failing
Force push to shared branchDestroys teammates' workRebase locally, only force-push your own branches
Committing secrets "just temporarily"Git history is permanentNever, always use .env.example
"It's just a test credential"Real bad actors scan GitHubRotate and remove from history
rm -rf based on LLM suggestionLLMs hallucinate pathsVerify path manually, dry-run with ls first

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.