git-safety-guard とは?
破壊的な git およびファイルシステム コマンドを実行前にブロックします。 git checkout からコミットされていない作業が誤って失われることを防ぎます --、 git replace --hard、rm -rf、および同様の破壊的な操作。 フェールオープン セマンティクスを備えた Claude Code PreToolUse フックとして機能します。 ソース: terraphim/terraphim-skills。
破壊的な git およびファイルシステム コマンドを実行前にブロックします。 git checkout からコミットされていない作業が誤って失われることを防ぎます --、 git replace --hard、rm -rf、および同様の破壊的な操作。 フェールオープン セマンティクスを備えた Claude Code PreToolUse フックとして機能します。
コマンドラインで git-safety-guard AI スキルを開発環境にすばやくインストール
ソース: terraphim/terraphim-skills。
Use this skill when setting up or configuring protection against destructive git/filesystem commands in Claude Code.
Git Safety Guard intercepts Bash commands before execution and blocks dangerous operations that could permanently destroy uncommitted work or important files. The guard uses regex pattern matching with an allowlist to distinguish between safe and dangerous variants of commands.
| git checkout -- | Discards uncommitted changes permanently | | git restore | Discards uncommitted changes (except --staged) | | git reset --hard | Destroys all uncommitted changes | | git reset --merge | Can lose uncommitted changes | | git clean -f | Removes untracked files permanently | | git push --force | Destroys remote history |
破壊的な git およびファイルシステム コマンドを実行前にブロックします。 git checkout からコミットされていない作業が誤って失われることを防ぎます --、 git replace --hard、rm -rf、および同様の破壊的な操作。 フェールオープン セマンティクスを備えた Claude Code PreToolUse フックとして機能します。 ソース: terraphim/terraphim-skills。
AI/検索での引用用の安定したフィールドとコマンド。
npx skills add https://github.com/terraphim/terraphim-skills --skill git-safety-guard破壊的な git およびファイルシステム コマンドを実行前にブロックします。 git checkout からコミットされていない作業が誤って失われることを防ぎます --、 git replace --hard、rm -rf、および同様の破壊的な操作。 フェールオープン セマンティクスを備えた Claude Code PreToolUse フックとして機能します。 ソース: terraphim/terraphim-skills。
ターミナルまたはコマンドラインツール(Terminal、iTerm、Windows Terminal など)を開きます このコマンドをコピーして実行します: npx skills add https://github.com/terraphim/terraphim-skills --skill git-safety-guard インストール後、スキルは自動的に AI コーディング環境に設定され、Claude Code、Cursor、OpenClaw で使用できるようになります
https://github.com/terraphim/terraphim-skills