From b8746636d138c76040f21a317928599e47ae7691 Mon Sep 17 00:00:00 2001 From: Zhongwei Li Date: Sun, 30 Nov 2025 08:52:38 +0800 Subject: [PATCH] Initial commit --- .claude-plugin/plugin.json | 12 ++++++++++ README.md | 3 +++ hooks/hooks.json | 15 +++++++++++++ plugin.lock.json | 45 ++++++++++++++++++++++++++++++++++++++ 4 files changed, 75 insertions(+) create mode 100644 .claude-plugin/plugin.json create mode 100644 README.md create mode 100644 hooks/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..7db921c --- /dev/null +++ b/.claude-plugin/plugin.json @@ -0,0 +1,12 @@ +{ + "name": "python-formatter-black", + "description": "Automatically format Python files with Black after Write/Edit/MultiEdit operations", + "version": "1.0.1", + "author": { + "name": "robbyt", + "email": "robbyt@robbyt.net" + }, + "hooks": [ + "./hooks" + ] +} \ No newline at end of file diff --git a/README.md b/README.md new file mode 100644 index 0000000..79549c2 --- /dev/null +++ b/README.md @@ -0,0 +1,3 @@ +# python-formatter-black + +Automatically format Python files with Black after Write/Edit/MultiEdit operations diff --git a/hooks/hooks.json b/hooks/hooks.json new file mode 100644 index 0000000..efa27db --- /dev/null +++ b/hooks/hooks.json @@ -0,0 +1,15 @@ +{ + "hooks": { + "PostToolUse": [ + { + "matcher": "Write|Edit|MultiEdit", + "hooks": [ + { + "type": "command", + "command": "${CLAUDE_PLUGIN_ROOT}/scripts/format-python.sh" + } + ] + } + ] + } +} diff --git a/plugin.lock.json b/plugin.lock.json new file mode 100644 index 0000000..6a18869 --- /dev/null +++ b/plugin.lock.json @@ -0,0 +1,45 @@ +{ + "$schema": "internal://schemas/plugin.lock.v1.json", + "pluginId": "gh:robbyt/claude-skills:plugins/python-formatter-black", + "normalized": { + "repo": null, + "ref": "refs/tags/v20251128.0", + "commit": "719c6042934280816d56c19441a37efcc7ff47b9", + "treeHash": "e74689d5a773534f525b3fabd7395f1cdd01a58629cc907ef453afc4768fab20", + "generatedAt": "2025-11-28T10:28:00.903888Z", + "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": "python-formatter-black", + "description": "Automatically format Python files with Black after Write/Edit/MultiEdit operations", + "version": "1.0.1" + }, + "content": { + "files": [ + { + "path": "README.md", + "sha256": "e29872933b4eaec0b4b196a3840c9f4d5fc92ee28801ebe631abea5d6bcb309c" + }, + { + "path": "hooks/hooks.json", + "sha256": "c4b75231d258d39432e78d9b7dd233dcbd1dcb047aa6b1a5e72757f74f510cdd" + }, + { + "path": ".claude-plugin/plugin.json", + "sha256": "6202ec0cd8ef6af7843751e55c0fdb3f4834abc91f47b3c8459148bbd8e4d973" + } + ], + "dirSha256": "e74689d5a773534f525b3fabd7395f1cdd01a58629cc907ef453afc4768fab20" + }, + "security": { + "scannedAt": null, + "scannerVersion": null, + "flags": [] + } +} \ No newline at end of file