[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M7198X4M0SHJ3B4TC614G3PH":3,"skill-same:01M7198X4M0SHJ3B4TC614G3PH":82},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":39,"linkOnly":40,"markdownContent":41,"markdownBody":42,"frontMatter":43,"refName":47,"commitSha":48,"skillDirectory":49,"forksCount":50,"repositoryHtmlUrl":51,"repositoryHomepageUrl":52,"ownerHtmlUrl":53,"ownerBlogUrl":6,"ownerDescription":54,"updatedAt":55,"install":56,"resources":69},"01M7198X4M0SHJ3B4TC614G3PH","git-guardrails-claude-code",null,"Set up Claude Code hooks to block dangerous git commands (push, reset --hard, clean, branch -D, etc.) before they execute. Use when user wants to prevent destructive git operations, add git safety hooks, or block git push\u002Freset in Claude Code.","fderuiter\u002Fderuiter.dev","fderuiter","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F127706008?v=4","01M6C40AWP9EPQBS3EG0RF5DRD","Frederick de Ruiter","01M7198E09Z6HET9MCJ9X3G8T4",1,"MIT","https:\u002F\u002Fgithub.com\u002Ffderuiter\u002Fderuiter.dev\u002Fblob\u002Fmain\u002F.agents\u002Fskills\u002Fgit-guardrails-claude-code\u002FSKILL.md",[],[19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38],"git guardrails","code","git guardrails claude code","git","Guardrails","block","operations","reset","when","matt pocock","use","claude code hooks","clean","up","hooks","git operations","git push","push","branch","SET","2026-11-10 10:12:30",false,"---\nname: git-guardrails-claude-code\ndescription: \"Set up Claude Code hooks to block dangerous git commands (push, reset --hard, clean, branch -D, etc.) before they execute. Use when user wants to prevent destructive git operations, add git safety hooks, or block git push\u002Freset in Claude Code.\"\nlicense: MIT\nmetadata:\n  author: Matt Pocock\n  version: \"1.0\"\n---\n\n# Setup Git Guardrails\n\nSets up a PreToolUse hook that intercepts and blocks dangerous git commands before Claude executes them.\n\n## What Gets Blocked\n\n- `git push` (all variants including `--force`)\n- `git reset --hard`\n- `git clean -f` \u002F `git clean -fd`\n- `git branch -D`\n- `git checkout .` \u002F `git restore .`\n\nWhen blocked, Claude sees a message telling it that it does not have authority to access these commands.\n\n## Steps\n\n### 1. Ask scope\n\nAsk the user: install for **this project only** (`.claude\u002Fsettings.json`) or **all projects** (`~\u002F.claude\u002Fsettings.json`)?\n\n### 2. Copy the hook script\n\nThe bundled script is at: [scripts\u002Fblock-dangerous-git.sh](.\u002Freferences\u002Fblock-dangerous-git.sh)\n\nCopy it to the target location based on scope:\n\n- **Project**: `.claude\u002Fhooks\u002Fblock-dangerous-git.sh`\n- **Global**: `~\u002F.claude\u002Fhooks\u002Fblock-dangerous-git.sh`\n\nMake it executable with `chmod +x`.\n\n### 3. Add hook to settings\n\nAdd to the appropriate settings file:\n\n**Project** (`.claude\u002Fsettings.json`):\n\n```json\n{\n  \"hooks\": {\n    \"PreToolUse\": [\n      {\n        \"matcher\": \"Bash\",\n        \"hooks\": [\n          {\n            \"type\": \"command\",\n            \"command\": \"\\\"$CLAUDE_PROJECT_DIR\\\"\u002F.claude\u002Fhooks\u002Fblock-dangerous-git.sh\"\n          }\n        ]\n      }\n    ]\n  }\n}\n```\n\n**Global** (`~\u002F.claude\u002Fsettings.json`):\n\n```json\n{\n  \"hooks\": {\n    \"PreToolUse\": [\n      {\n        \"matcher\": \"Bash\",\n        \"hooks\": [\n          {\n            \"type\": \"command\",\n            \"command\": \"~\u002F.claude\u002Fhooks\u002Fblock-dangerous-git.sh\"\n          }\n        ]\n      }\n    ]\n  }\n}\n```\n\nIf the settings file already exists, merge the hook into the existing `hooks.PreToolUse` array. Don't overwrite other settings.\n\n### 4. Ask about customization\n\nAsk if user wants to add or remove any patterns from the blocked list. Edit the copied script accordingly.\n\n### 5. Verify\n\nRun a quick test:\n\n```bash\necho '{\"tool_input\":{\"command\":\"git push origin main\"}}' | \u003Cpath-to-script>\n```\n\nShould exit with code 2 and print a BLOCKED message to stderr.\n","# Setup Git Guardrails\n\nSets up a PreToolUse hook that intercepts and blocks dangerous git commands before Claude executes them.\n\n## What Gets Blocked\n\n- `git push` (all variants including `--force`)\n- `git reset --hard`\n- `git clean -f` \u002F `git clean -fd`\n- `git branch -D`\n- `git checkout .` \u002F `git restore .`\n\nWhen blocked, Claude sees a message telling it that it does not have authority to access these commands.\n\n## Steps\n\n### 1. Ask scope\n\nAsk the user: install for **this project only** (`.claude\u002Fsettings.json`) or **all projects** (`~\u002F.claude\u002Fsettings.json`)?\n\n### 2. Copy the hook script\n\nThe bundled script is at: [scripts\u002Fblock-dangerous-git.sh](.\u002Freferences\u002Fblock-dangerous-git.sh)\n\nCopy it to the target location based on scope:\n\n- **Project**: `.claude\u002Fhooks\u002Fblock-dangerous-git.sh`\n- **Global**: `~\u002F.claude\u002Fhooks\u002Fblock-dangerous-git.sh`\n\nMake it executable with `chmod +x`.\n\n### 3. Add hook to settings\n\nAdd to the appropriate settings file:\n\n**Project** (`.claude\u002Fsettings.json`):\n\n```json\n{\n  \"hooks\": {\n    \"PreToolUse\": [\n      {\n        \"matcher\": \"Bash\",\n        \"hooks\": [\n          {\n            \"type\": \"command\",\n            \"command\": \"\\\"$CLAUDE_PROJECT_DIR\\\"\u002F.claude\u002Fhooks\u002Fblock-dangerous-git.sh\"\n          }\n        ]\n      }\n    ]\n  }\n}\n```\n\n**Global** (`~\u002F.claude\u002Fsettings.json`):\n\n```json\n{\n  \"hooks\": {\n    \"PreToolUse\": [\n      {\n        \"matcher\": \"Bash\",\n        \"hooks\": [\n          {\n            \"type\": \"command\",\n            \"command\": \"~\u002F.claude\u002Fhooks\u002Fblock-dangerous-git.sh\"\n          }\n        ]\n      }\n    ]\n  }\n}\n```\n\nIf the settings file already exists, merge the hook into the existing `hooks.PreToolUse` array. Don't overwrite other settings.\n\n### 4. Ask about customization\n\nAsk if user wants to add or remove any patterns from the blocked list. Edit the copied script accordingly.\n\n### 5. Verify\n\nRun a quick test:\n\n```bash\necho '{\"tool_input\":{\"command\":\"git push origin main\"}}' | \u003Cpath-to-script>\n```\n\nShould exit with code 2 and print a BLOCKED message to stderr.\n",{"name":5,"license":15,"metadata":44,"description":7},{"author":45,"version":46},"Matt Pocock","1.0","main","c47b6da3146618c87c6126686b1865c80db104de",".agents\u002Fskills\u002Fgit-guardrails-claude-code",0,"https:\u002F\u002Fgithub.com\u002Ffderuiter\u002Fderuiter.dev","https:\u002F\u002Fderuiter.dev","https:\u002F\u002Fgithub.com\u002Ffderuiter","Clinical Data Specialist at @Bright-Research \r\n\r\nInterests in Photogrammetry, Data Analytics + Pipelines, Mathematics, and AI\u002FML.\r\n\r\nPython, Rust, TS.","2026-11-15 04:27:26",{"source":8,"skillName":5,"commands":57,"prompt":67,"zipAvailable":68},[58,61,64],{"tool":59,"command":60},"npx","npx skills add fderuiter\u002Fderuiter.dev --skill git-guardrails-claude-code",{"tool":62,"command":63},"bunx","bunx skills add fderuiter\u002Fderuiter.dev --skill git-guardrails-claude-code",{"tool":65,"command":66},"pnpm","pnpm dlx skills add fderuiter\u002Fderuiter.dev --skill git-guardrails-claude-code","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Ffderuiter\u002Fderuiter.dev\u002Fblob\u002Fmain\u002F.agents\u002Fskills\u002Fgit-guardrails-claude-code\u002FSKILL.md",true,[70,76],{"path":71,"resourceType":72,"resourceTypeDesc":73,"sizeBytes":74,"sourceHtmlUrl":75},"agents\u002Fopenai.yaml","REFERENCE","参考文档",112,"https:\u002F\u002Fgithub.com\u002Ffderuiter\u002Fderuiter.dev\u002Fblob\u002Fmain\u002F.agents\u002Fskills\u002Fgit-guardrails-claude-code\u002Fagents\u002Fopenai.yaml",{"path":77,"resourceType":78,"resourceTypeDesc":79,"sizeBytes":80,"sourceHtmlUrl":81},"references\u002Fblock-dangerous-git.sh","SCRIPT","脚本",507,"https:\u002F\u002Fgithub.com\u002Ffderuiter\u002Fderuiter.dev\u002Fblob\u002Fmain\u002F.agents\u002Fskills\u002Fgit-guardrails-claude-code\u002Freferences\u002Fblock-dangerous-git.sh",[83,91,113,136,158,170],{"skillNo":84,"name":85,"nameZh":6,"description":86,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":87,"categories":88,"keywords":89,"publishedAt":90},"01M72JCP281YVCJDHCTSAFJE95","wayfinder","Plan a huge chunk of work (more than one agent session can hold) as a shared map of decision tickets on your issue tracker, and resolve them one at a time until the way to the destination is clear.","https:\u002F\u002Fgithub.com\u002Ffderuiter\u002Fderuiter.dev\u002Fblob\u002Fmain\u002F.agents\u002Fskills\u002Fwayfinder\u002FSKILL.md",[],[],"2026-11-10 22:39:42",{"skillNo":92,"name":93,"nameZh":6,"description":94,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":95,"licenseFileUrl":6,"sourceHtmlUrl":96,"categories":97,"keywords":98,"publishedAt":39},"01M719B069WAWZK66D6XC5VEP6","steward","Drive a deruiter.dev pull request to green. Use when opening a PR, answering CI failures or review comments on one, or resolving a merge conflict with main.","Apache-2.0","https:\u002F\u002Fgithub.com\u002Ffderuiter\u002Fderuiter.dev\u002Fblob\u002Fmain\u002F.claude\u002Fskills\u002Fsteward\u002FSKILL.md",[],[93,99,100,101,102,103,104,105,47,29,27,106,107,108,109,110,111,112],"pull","drive","conflict","pr","green","ci","dev","comments","review","with","pull request","merge","request","opening a pr",{"skillNo":114,"name":115,"nameZh":6,"description":116,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":95,"licenseFileUrl":6,"sourceHtmlUrl":117,"categories":118,"keywords":119,"publishedAt":39},"01M719AY21D3SEW98GS1Y4413G","run-portfolio","Build, run, and drive the fderuiter\u002Fderuiter.dev Next.js web app. Use when asked to start the portfolio site, run the dev server, take a screenshot of a page (home, \u002Fpatrol, \u002Fcrf, \u002Fproof, arcade games, etc.), or interact with its UI.","https:\u002F\u002Fgithub.com\u002Ffderuiter\u002Fderuiter.dev\u002Fblob\u002Fmain\u002F.claude\u002Fskills\u002Frun-portfolio\u002FSKILL.md",[],[120,121,122,105,123,124,125,126,127,128,108,129,130,27,29,131,132,133,134,135],"run","portfolio","run portfolio","start","take","build","next","web","server","home","Next.js","take a screenshot","patrol","app","page","games",{"skillNo":137,"name":138,"nameZh":6,"description":139,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":140,"sourceHtmlUrl":141,"categories":142,"keywords":143,"publishedAt":39},"01M719AT8224QX2CRMQV6NV62M","humanizer","Edit deruiter.dev prose so it reads like Fred wrote it, without changing what it says. Use when writing or editing a blog post, case study, page or game copy, the README, docs, a PR body, an issue or a commit message in this repository.","https:\u002F\u002Fgithub.com\u002Ffderuiter\u002Fderuiter.dev\u002Fblob\u002Fmain\u002F.claude\u002Fskills\u002Fhumanizer\u002FLICENSE","https:\u002F\u002Fgithub.com\u002Ffderuiter\u002Fderuiter.dev\u002Fblob\u002Fmain\u002F.claude\u002Fskills\u002Fhumanizer\u002FSKILL.md",[],[138,144,145,27,146,147,148,149,150,151,152,153,102,134,154,155,156,105,29,157],"blog post","writing","commit","game","message","pr body","repository","edit","issue","body","README","editing","study","commit message",{"skillNo":159,"name":160,"nameZh":6,"description":161,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":162,"categories":163,"keywords":164,"publishedAt":39},"01M719ARDTHZN4F9Q9DRFQ3DWB","writing-shape","Writing, exploit: shape raw material into an article, paragraph by paragraph.","https:\u002F\u002Fgithub.com\u002Ffderuiter\u002Fderuiter.dev\u002Fblob\u002Fmain\u002F.agents\u002Fskills\u002Fwriting-shape\u002FSKILL.md",[],[145,165,166,167,168,169,28],"writing shape","shape","article","exploit","material",{"skillNo":171,"name":172,"nameZh":6,"description":173,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":174,"categories":175,"keywords":176,"publishedAt":39},"01M719AP8B84FCM0S2H6DMJ8J8","writing-fragments","Writing, explore: mine raw fragments, no structure yet.","https:\u002F\u002Fgithub.com\u002Ffderuiter\u002Fderuiter.dev\u002Fblob\u002Fmain\u002F.agents\u002Fskills\u002Fwriting-fragments\u002FSKILL.md",[],[177,145,28,178,179,180],"writing fragments","explore","mine","structure"]