diff --git a/settings.json b/settings.json index 2aa8d9b..856391e 100644 --- a/settings.json +++ b/settings.json @@ -21,11 +21,9 @@ "Bash(git push --force*)", "Bash(git push *--force*)", "Bash(git reset --hard*)", - "Edit(~/.bashrc)", "Edit(~/.zshrc)", "Edit(~/.ssh/**)", - "Read(~/.ssh/**)", "Read(~/.gnupg/**)", "Read(~/.aws/**)", @@ -51,6 +49,10 @@ { "matcher": "Bash", "hooks": [ + { + "type": "command", + "command": "npx --yes block-no-verify@1.1.2" + }, { "type": "command", "command": "CMD=$(jq -r '.tool_input.command'); if echo \"$CMD\" | grep -qiE '(^|;[[:space:]]*|&&[[:space:]]*|[|][|][[:space:]]*|[|][[:space:]]*)rm[[:space:]]' && echo \"$CMD\" | grep -qiE '(^|[[:space:]])-[a-zA-Z]*[rR]|--recursive' && echo \"$CMD\" | grep -qiE '(^|[[:space:]])-[a-zA-Z]*[fF]|--force'; then echo 'BLOCKED: Use trash instead of rm -rf' >&2; exit 2; fi"