From 70666f6b1efc32db8e885022196c43fec4005938 Mon Sep 17 00:00:00 2001 From: Zhongwei Li Date: Sat, 29 Nov 2025 18:50:32 +0800 Subject: [PATCH] Initial commit --- .claude-plugin/plugin.json | 16 +++++ README.md | 3 + commands/claudisms-reload.md | 6 ++ commands/claudisms-settings.md | 6 ++ hooks.json | 116 +++++++++++++++++++++++++++++++++ plugin.lock.json | 53 +++++++++++++++ 6 files changed, 200 insertions(+) create mode 100644 .claude-plugin/plugin.json create mode 100644 README.md create mode 100644 commands/claudisms-reload.md create mode 100644 commands/claudisms-settings.md create mode 100644 hooks.json create mode 100644 plugin.lock.json diff --git a/.claude-plugin/plugin.json b/.claude-plugin/plugin.json new file mode 100644 index 0000000..e2c9206 --- /dev/null +++ b/.claude-plugin/plugin.json @@ -0,0 +1,16 @@ +{ + "name": "claudisms", + "description": "Operational guidelines: terse responses, sequential execution, no destructive ops without confirmation", + "version": "2.2.0", + "author": { + "name": "Jefferson Warrior", + "github": "https://github.com/jeffersonwarrior" + }, + "commands": [ + "./commands/claudisms-settings.md", + "./commands/claudisms-reload.md" + ], + "hooks": [ + "./hooks.json" + ] +} \ No newline at end of file diff --git a/README.md b/README.md new file mode 100644 index 0000000..4c51af5 --- /dev/null +++ b/README.md @@ -0,0 +1,3 @@ +# claudisms + +Operational guidelines: terse responses, sequential execution, no destructive ops without confirmation diff --git a/commands/claudisms-reload.md b/commands/claudisms-reload.md new file mode 100644 index 0000000..c91ba56 --- /dev/null +++ b/commands/claudisms-reload.md @@ -0,0 +1,6 @@ +--- +name: claudisms-reload +description: Reload Claudisms settings without restarting session +--- + +!~/.claude/plugins/marketplaces/claudisms/commands/claudisms-reload.sh diff --git a/commands/claudisms-settings.md b/commands/claudisms-settings.md new file mode 100644 index 0000000..0f09683 --- /dev/null +++ b/commands/claudisms-settings.md @@ -0,0 +1,6 @@ +--- +name: claudisms-settings +description: Manage Claudisms plugin settings +--- + +!~/.claude/plugins/marketplaces/claudisms/commands/claudisms-settings.sh $ARGUMENTS diff --git a/hooks.json b/hooks.json new file mode 100644 index 0000000..e6a5aa9 --- /dev/null +++ b/hooks.json @@ -0,0 +1,116 @@ +{ + "hooks": { + "SessionStart": [ + { + "hooks": [ + { + "type": "command", + "command": "${CLAUDE_PLUGIN_ROOT}/hooks-handlers/session-start.sh" + } + ] + } + ], + "PreToolUse": [ + { + "matcher": "Write", + "filePathMatcher": "**/*README*.md", + "hooks": [ + { + "type": "command", + "command": "${CLAUDE_PLUGIN_ROOT}/hooks-handlers/before-md-write.sh" + } + ] + }, + { + "matcher": "Write", + "filePathMatcher": "**/*SETUP*.md", + "hooks": [ + { + "type": "command", + "command": "${CLAUDE_PLUGIN_ROOT}/hooks-handlers/before-md-write.sh" + } + ] + }, + { + "matcher": "Write", + "filePathMatcher": "**/claude.md", + "hooks": [ + { + "type": "command", + "command": "${CLAUDE_PLUGIN_ROOT}/hooks-handlers/before-md-write.sh" + } + ] + }, + { + "matcher": "Write", + "filePathMatcher": "**/CLAUDE.md", + "hooks": [ + { + "type": "command", + "command": "${CLAUDE_PLUGIN_ROOT}/hooks-handlers/before-md-write.sh" + } + ] + }, + { + "matcher": "Bash", + "commandMatcher": ".*rm\\s+-[^\\s]*r[^\\s]*f.*", + "hooks": [ + { + "type": "command", + "command": "${CLAUDE_PLUGIN_ROOT}/hooks-handlers/before-destructive.sh" + } + ] + }, + { + "matcher": "Bash", + "commandMatcher": ".*rm\\s+-[^\\s]*f[^\\s]*r.*", + "hooks": [ + { + "type": "command", + "command": "${CLAUDE_PLUGIN_ROOT}/hooks-handlers/before-destructive.sh" + } + ] + }, + { + "matcher": "Bash", + "commandMatcher": ".*git\\s+push.*", + "hooks": [ + { + "type": "command", + "command": "${CLAUDE_PLUGIN_ROOT}/hooks-handlers/before-destructive.sh" + } + ] + }, + { + "matcher": "Bash", + "commandMatcher": "(?i).*DROP\\s+(TABLE|DATABASE).*", + "hooks": [ + { + "type": "command", + "command": "${CLAUDE_PLUGIN_ROOT}/hooks-handlers/before-destructive.sh" + } + ] + }, + { + "matcher": "Bash", + "commandMatcher": "(?i).*DELETE\\s+FROM.*", + "hooks": [ + { + "type": "command", + "command": "${CLAUDE_PLUGIN_ROOT}/hooks-handlers/before-destructive.sh" + } + ] + }, + { + "matcher": "Bash", + "commandMatcher": "(?i).*TRUNCATE\\s+TABLE.*", + "hooks": [ + { + "type": "command", + "command": "${CLAUDE_PLUGIN_ROOT}/hooks-handlers/before-destructive.sh" + } + ] + } + ] + } +} diff --git a/plugin.lock.json b/plugin.lock.json new file mode 100644 index 0000000..3fd4765 --- /dev/null +++ b/plugin.lock.json @@ -0,0 +1,53 @@ +{ + "$schema": "internal://schemas/plugin.lock.v1.json", + "pluginId": "gh:jeffersonwarrior/claudisms:", + "normalized": { + "repo": null, + "ref": "refs/tags/v20251128.0", + "commit": "5fb4201c8adc4829f81fb5da6384a67e0754e910", + "treeHash": "4fc5a44d42114a69080f1ab99a944f9e0c2f87d8f5a5df446fc69609a097b007", + "generatedAt": "2025-11-28T10:18:00.785368Z", + "toolVersion": "publish_plugins.py@0.2.0" + }, + "origin": { + "remote": "git@github.com:zhongweili/42plugin-data.git", + "branch": "master", + "commit": "aa1497ed0949fd50e99e70d6324a29c5b34f9390", + "repoRoot": "/Users/zhongweili/projects/openmind/42plugin-data" + }, + "manifest": { + "name": "claudisms", + "description": "Operational guidelines: terse responses, sequential execution, no destructive ops without confirmation", + "version": "2.2.0" + }, + "content": { + "files": [ + { + "path": "README.md", + "sha256": "0747fd5f4727acf9cb69033adc95a246e72838f7a2ff70c3172080ec40fb7108" + }, + { + "path": "hooks.json", + "sha256": "4844332133a8c410691b7c3ee95843fb647282b55dc90a2dbcc4705af86a470a" + }, + { + "path": ".claude-plugin/plugin.json", + "sha256": "7e0f2e3225c33df5c6260b83bcf2df49e8e1c591a1b89093f96550c0aa6c3100" + }, + { + "path": "commands/claudisms-reload.md", + "sha256": "11dbda40214d9639c2973c9ac47da876206d43326d3d7a7871ddf95076188cf6" + }, + { + "path": "commands/claudisms-settings.md", + "sha256": "b40b37b5e0d22b3e9ef127d658eba69b48702db72f96c3d89b8ac7afc1abf2a6" + } + ], + "dirSha256": "4fc5a44d42114a69080f1ab99a944f9e0c2f87d8f5a5df446fc69609a097b007" + }, + "security": { + "scannedAt": null, + "scannerVersion": null, + "flags": [] + } +} \ No newline at end of file