@thebushidocollective/han 1.34.2 → 1.35.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/lib/build-info.generated.d.ts +1 -1
- package/dist/lib/build-info.generated.js +1 -1
- package/dist/lib/commands/hook/dispatch.d.ts +3 -0
- package/dist/lib/commands/hook/dispatch.d.ts.map +1 -0
- package/dist/lib/commands/hook/dispatch.js +143 -0
- package/dist/lib/commands/hook/dispatch.js.map +1 -0
- package/dist/lib/commands/hook/index.d.ts.map +1 -1
- package/dist/lib/commands/hook/index.js +2 -0
- package/dist/lib/commands/hook/index.js.map +1 -1
- package/package.json +6 -6
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export declare const HAN_VERSION = "1.
|
|
1
|
+
export declare const HAN_VERSION = "1.35.0";
|
|
2
2
|
export declare const DETECT_PLUGINS_PROMPT = "<!--\nThis prompt template is dynamically enhanced in shared.ts with:\n1. GIT REPOSITORY section - Remote URL to determine hosting platform (GitHub, GitLab, etc.)\n2. CURRENTLY INSTALLED PLUGINS section - List of plugins already installed (if any)\n3. CODEBASE STATISTICS section - File extensions and config file names from codebase-analyzer.ts\n4. AVAILABLE PLUGINS IN MARKETPLACE section - Plugin list from marketplace.json\n\nThese sections are appended to this base prompt at runtime.\n-->\n\n# Han Plugin Installer Assistant\n\nYou are a Han plugin installer assistant. Your goal is to analyze the current codebase and recommend appropriate Claude Code plugins from the Han marketplace.\n\nThe available plugins from the marketplace are provided below. ONLY recommend plugins from this list.\n\n## Plugin Categories\n\n- **jutsu-\\*** (\u6B66\u5668 weapons): Skills for specific technologies and frameworks\n- **do-\\*** (\u9053 disciplines): Specialized agents for development practices and workflows\n- **hashi-\\*** (\u5148\u751F teachers): MCP servers for external integrations\n- **bushido**: Core quality principles (ALWAYS recommend this)\n\n## Your Analysis Process\n\n### STEP 1: Analyze currently installed plugins (if provided)\n\n- Check if CURRENTLY INSTALLED PLUGINS section is provided in the prompt\n- If provided, you should:\n - **Understand why each plugin was likely added**: Look at plugin descriptions and infer original use case\n - Example: `jutsu-typescript` suggests TypeScript development\n - Example: `hashi-github` suggests GitHub integration needs\n - Example: `do-frontend-development` suggests frontend focus\n - **Determine if each plugin is still relevant**:\n - Use the codebase statistics and configuration files to verify if the technology/practice is still in use\n - A plugin is still relevant if its associated technology/practice is actively used in the codebase\n - A plugin may be irrelevant if:\n - The technology was removed (e.g., no more .ts files but jutsu-typescript is installed)\n - The project migrated to a different platform (e.g., moved from GitHub to GitLab)\n - The framework changed (e.g., migrated from React to Vue)\n - **Keep relevant plugins in your recommendations**: If a plugin is still relevant, include it in your final list\n - **Exclude irrelevant plugins**: If a plugin is no longer needed, do not include it in your recommendations\n\n### STEP 2: Check git repository hosting platform (if provided)\n\n- Check if GIT REPOSITORY section is provided in the prompt\n- If provided, examine the remote URL to determine the hosting platform:\n - URLs containing `github.com` \u2192 recommend `hashi-github`\n - URLs containing `gitlab.com` or other GitLab instances \u2192 recommend `hashi-gitlab`\n - This helps integrate Claude Code with the project's issue tracking, PRs/MRs, and CI/CD\n\n### STEP 3: Review pre-computed codebase statistics (if provided)\n\n- Check if CODEBASE STATISTICS section is provided in the prompt\n- If provided, you have:\n - **File extension counts** (e.g., .ts: 456, .py: 123) - interpret these as technologies\n - .ts, .tsx, .jsx = TypeScript/JavaScript\n - .py = Python\n - .rs = Rust\n - .go = Go\n - .rb = Ruby\n - .ex, .exs = Elixir\n - .vue = Vue.js\n - etc.\n - **Config file names** (e.g., package.json, Cargo.toml, go.mod) - these reveal frameworks and tools\n- If statistics are NOT provided, use Glob to discover file types\n - Example: glob(\"\\*_/_.ts\") to find TypeScript files\n - Example: glob(\"\\*_/_.py\") to find Python files\n\n### STEP 4: Examine key configuration files\n\n- Config files are already identified in the statistics (if provided)\n- Use Read tool to examine important config files:\n - package.json - reveals Node.js frameworks, dependencies\n - Cargo.toml - reveals Rust dependencies\n - go.mod - reveals Go dependencies\n - requirements.txt, pyproject.toml - reveals Python dependencies\n - mix.exs - reveals Elixir dependencies\n- Use Grep to search for framework-specific patterns\n - Example: grep(\"import.\\*react\") to confirm React usage\n - Example: grep(\"from django\") to confirm Django usage\n\n### STEP 5: Identify technologies and patterns\n\n- Programming languages (TypeScript, Python, Go, Rust, Ruby, etc.)\n- Frameworks and libraries (React, Vue, Django, Rails, etc.)\n- Testing frameworks (Jest, Pytest, RSpec, etc.)\n- Build tools and infrastructure (Docker, Kubernetes, etc.)\n- Development practices (API development, frontend development, mobile, etc.)\n- Content patterns (blog posts, documentation, CMS usage)\n- CI/CD configurations\n- Accessibility tooling\n\n### STEP 6: Match findings to available plugins\n\n- Look at the plugin descriptions and keywords below\n- Cross-reference detected technologies with available jutsu-\\* plugins\n- Cross-reference development practices with available do-\\* plugins\n- Cross-reference integrations with available hashi-\\* plugins\n- ONLY recommend plugins from the list provided\n- Aim for 3-8 total plugins that best match the codebase\n- Always include \"bushido\" as it's the core plugin\n\n## Output Format\n\nReturn ONLY a JSON array of recommended plugin names from the available plugins list:\n\n```json\n[\"bushido\", \"jutsu-typescript\", \"jutsu-react\", \"do-frontend-development\"]\n```\n\n**CRITICAL**: Only recommend plugins that appear in the AVAILABLE PLUGINS list below. Never recommend plugins not in the list.\n";
|
|
3
3
|
//# sourceMappingURL=build-info.generated.d.ts.map
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
// Auto-generated by build-bundle.js - DO NOT EDIT
|
|
2
|
-
export const HAN_VERSION = "1.
|
|
2
|
+
export const HAN_VERSION = "1.35.0";
|
|
3
3
|
export const DETECT_PLUGINS_PROMPT = "<!--\nThis prompt template is dynamically enhanced in shared.ts with:\n1. GIT REPOSITORY section - Remote URL to determine hosting platform (GitHub, GitLab, etc.)\n2. CURRENTLY INSTALLED PLUGINS section - List of plugins already installed (if any)\n3. CODEBASE STATISTICS section - File extensions and config file names from codebase-analyzer.ts\n4. AVAILABLE PLUGINS IN MARKETPLACE section - Plugin list from marketplace.json\n\nThese sections are appended to this base prompt at runtime.\n-->\n\n# Han Plugin Installer Assistant\n\nYou are a Han plugin installer assistant. Your goal is to analyze the current codebase and recommend appropriate Claude Code plugins from the Han marketplace.\n\nThe available plugins from the marketplace are provided below. ONLY recommend plugins from this list.\n\n## Plugin Categories\n\n- **jutsu-\\*** (武器 weapons): Skills for specific technologies and frameworks\n- **do-\\*** (道 disciplines): Specialized agents for development practices and workflows\n- **hashi-\\*** (先生 teachers): MCP servers for external integrations\n- **bushido**: Core quality principles (ALWAYS recommend this)\n\n## Your Analysis Process\n\n### STEP 1: Analyze currently installed plugins (if provided)\n\n- Check if CURRENTLY INSTALLED PLUGINS section is provided in the prompt\n- If provided, you should:\n - **Understand why each plugin was likely added**: Look at plugin descriptions and infer original use case\n - Example: `jutsu-typescript` suggests TypeScript development\n - Example: `hashi-github` suggests GitHub integration needs\n - Example: `do-frontend-development` suggests frontend focus\n - **Determine if each plugin is still relevant**:\n - Use the codebase statistics and configuration files to verify if the technology/practice is still in use\n - A plugin is still relevant if its associated technology/practice is actively used in the codebase\n - A plugin may be irrelevant if:\n - The technology was removed (e.g., no more .ts files but jutsu-typescript is installed)\n - The project migrated to a different platform (e.g., moved from GitHub to GitLab)\n - The framework changed (e.g., migrated from React to Vue)\n - **Keep relevant plugins in your recommendations**: If a plugin is still relevant, include it in your final list\n - **Exclude irrelevant plugins**: If a plugin is no longer needed, do not include it in your recommendations\n\n### STEP 2: Check git repository hosting platform (if provided)\n\n- Check if GIT REPOSITORY section is provided in the prompt\n- If provided, examine the remote URL to determine the hosting platform:\n - URLs containing `github.com` → recommend `hashi-github`\n - URLs containing `gitlab.com` or other GitLab instances → recommend `hashi-gitlab`\n - This helps integrate Claude Code with the project's issue tracking, PRs/MRs, and CI/CD\n\n### STEP 3: Review pre-computed codebase statistics (if provided)\n\n- Check if CODEBASE STATISTICS section is provided in the prompt\n- If provided, you have:\n - **File extension counts** (e.g., .ts: 456, .py: 123) - interpret these as technologies\n - .ts, .tsx, .jsx = TypeScript/JavaScript\n - .py = Python\n - .rs = Rust\n - .go = Go\n - .rb = Ruby\n - .ex, .exs = Elixir\n - .vue = Vue.js\n - etc.\n - **Config file names** (e.g., package.json, Cargo.toml, go.mod) - these reveal frameworks and tools\n- If statistics are NOT provided, use Glob to discover file types\n - Example: glob(\"\\*_/_.ts\") to find TypeScript files\n - Example: glob(\"\\*_/_.py\") to find Python files\n\n### STEP 4: Examine key configuration files\n\n- Config files are already identified in the statistics (if provided)\n- Use Read tool to examine important config files:\n - package.json - reveals Node.js frameworks, dependencies\n - Cargo.toml - reveals Rust dependencies\n - go.mod - reveals Go dependencies\n - requirements.txt, pyproject.toml - reveals Python dependencies\n - mix.exs - reveals Elixir dependencies\n- Use Grep to search for framework-specific patterns\n - Example: grep(\"import.\\*react\") to confirm React usage\n - Example: grep(\"from django\") to confirm Django usage\n\n### STEP 5: Identify technologies and patterns\n\n- Programming languages (TypeScript, Python, Go, Rust, Ruby, etc.)\n- Frameworks and libraries (React, Vue, Django, Rails, etc.)\n- Testing frameworks (Jest, Pytest, RSpec, etc.)\n- Build tools and infrastructure (Docker, Kubernetes, etc.)\n- Development practices (API development, frontend development, mobile, etc.)\n- Content patterns (blog posts, documentation, CMS usage)\n- CI/CD configurations\n- Accessibility tooling\n\n### STEP 6: Match findings to available plugins\n\n- Look at the plugin descriptions and keywords below\n- Cross-reference detected technologies with available jutsu-\\* plugins\n- Cross-reference development practices with available do-\\* plugins\n- Cross-reference integrations with available hashi-\\* plugins\n- ONLY recommend plugins from the list provided\n- Aim for 3-8 total plugins that best match the codebase\n- Always include \"bushido\" as it's the core plugin\n\n## Output Format\n\nReturn ONLY a JSON array of recommended plugin names from the available plugins list:\n\n```json\n[\"bushido\", \"jutsu-typescript\", \"jutsu-react\", \"do-frontend-development\"]\n```\n\n**CRITICAL**: Only recommend plugins that appear in the AVAILABLE PLUGINS list below. Never recommend plugins not in the list.\n";
|
|
4
4
|
//# sourceMappingURL=build-info.generated.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"dispatch.d.ts","sourceRoot":"","sources":["../../../../lib/commands/hook/dispatch.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAwKzC,wBAAgB,oBAAoB,CAAC,WAAW,EAAE,OAAO,GAAG,IAAI,CAiB/D"}
|
|
@@ -0,0 +1,143 @@
|
|
|
1
|
+
import { execSync } from "node:child_process";
|
|
2
|
+
import { getInstalledPlugins, HAN_MARKETPLACE_REPO, } from "../../shared.js";
|
|
3
|
+
/**
|
|
4
|
+
* Fetch a plugin's hooks.json from GitHub
|
|
5
|
+
*/
|
|
6
|
+
async function fetchPluginHooks(pluginName) {
|
|
7
|
+
// Determine plugin path based on naming convention
|
|
8
|
+
let pluginPath;
|
|
9
|
+
if (pluginName.startsWith("jutsu-")) {
|
|
10
|
+
pluginPath = `jutsu/${pluginName}`;
|
|
11
|
+
}
|
|
12
|
+
else if (pluginName.startsWith("do-")) {
|
|
13
|
+
pluginPath = `do/${pluginName}`;
|
|
14
|
+
}
|
|
15
|
+
else if (pluginName.startsWith("hashi-")) {
|
|
16
|
+
pluginPath = `hashi/${pluginName}`;
|
|
17
|
+
}
|
|
18
|
+
else {
|
|
19
|
+
// Core plugins like 'bushido'
|
|
20
|
+
pluginPath = pluginName;
|
|
21
|
+
}
|
|
22
|
+
const url = `https://raw.githubusercontent.com/${HAN_MARKETPLACE_REPO}/refs/heads/main/${pluginPath}/hooks/hooks.json`;
|
|
23
|
+
try {
|
|
24
|
+
const response = await fetch(url);
|
|
25
|
+
if (!response.ok) {
|
|
26
|
+
// No hooks.json for this plugin, that's fine
|
|
27
|
+
return null;
|
|
28
|
+
}
|
|
29
|
+
return (await response.json());
|
|
30
|
+
}
|
|
31
|
+
catch {
|
|
32
|
+
// Network error or invalid JSON
|
|
33
|
+
return null;
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
/**
|
|
37
|
+
* Get the GitHub raw URL base for a plugin
|
|
38
|
+
*/
|
|
39
|
+
function getPluginGitHubBase(pluginName) {
|
|
40
|
+
let pluginPath;
|
|
41
|
+
if (pluginName.startsWith("jutsu-")) {
|
|
42
|
+
pluginPath = `jutsu/${pluginName}`;
|
|
43
|
+
}
|
|
44
|
+
else if (pluginName.startsWith("do-")) {
|
|
45
|
+
pluginPath = `do/${pluginName}`;
|
|
46
|
+
}
|
|
47
|
+
else if (pluginName.startsWith("hashi-")) {
|
|
48
|
+
pluginPath = `hashi/${pluginName}`;
|
|
49
|
+
}
|
|
50
|
+
else {
|
|
51
|
+
pluginPath = pluginName;
|
|
52
|
+
}
|
|
53
|
+
return `https://raw.githubusercontent.com/${HAN_MARKETPLACE_REPO}/refs/heads/main/${pluginPath}`;
|
|
54
|
+
}
|
|
55
|
+
/**
|
|
56
|
+
* Execute a command hook and return its output
|
|
57
|
+
*/
|
|
58
|
+
function executeCommandHook(command, pluginName, timeout) {
|
|
59
|
+
try {
|
|
60
|
+
// Replace ${CLAUDE_PLUGIN_ROOT} with GitHub raw URL for the plugin
|
|
61
|
+
// This allows hooks that reference plugin files to still work
|
|
62
|
+
const pluginBase = getPluginGitHubBase(pluginName);
|
|
63
|
+
const resolvedCommand = command.replace(/\$\{CLAUDE_PLUGIN_ROOT\}/g, pluginBase);
|
|
64
|
+
const output = execSync(resolvedCommand, {
|
|
65
|
+
encoding: "utf-8",
|
|
66
|
+
timeout,
|
|
67
|
+
stdio: ["pipe", "pipe", "pipe"],
|
|
68
|
+
shell: "/bin/sh",
|
|
69
|
+
cwd: process.cwd(),
|
|
70
|
+
});
|
|
71
|
+
return output.trim();
|
|
72
|
+
}
|
|
73
|
+
catch (error) {
|
|
74
|
+
// Command failed
|
|
75
|
+
const err = error;
|
|
76
|
+
return `[Error from ${pluginName}]: ${err.stderr || err.message || "Unknown error"}`;
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
/**
|
|
80
|
+
* Dispatch hooks of a specific type across all installed plugins
|
|
81
|
+
*/
|
|
82
|
+
async function dispatchHooks(hookType) {
|
|
83
|
+
// Get installed plugins from both scopes
|
|
84
|
+
const projectPlugins = getInstalledPlugins("project");
|
|
85
|
+
const localPlugins = getInstalledPlugins("local");
|
|
86
|
+
const installedPlugins = Array.from(new Set([...projectPlugins, ...localPlugins]));
|
|
87
|
+
if (installedPlugins.length === 0) {
|
|
88
|
+
// No plugins installed, nothing to dispatch
|
|
89
|
+
return;
|
|
90
|
+
}
|
|
91
|
+
const outputs = [];
|
|
92
|
+
// Process plugins in parallel for speed
|
|
93
|
+
const results = await Promise.all(installedPlugins.map(async (pluginName) => {
|
|
94
|
+
const pluginHooks = await fetchPluginHooks(pluginName);
|
|
95
|
+
if (!pluginHooks?.hooks?.[hookType]) {
|
|
96
|
+
return null;
|
|
97
|
+
}
|
|
98
|
+
const hookGroups = pluginHooks.hooks[hookType];
|
|
99
|
+
const pluginOutputs = [];
|
|
100
|
+
for (const group of hookGroups) {
|
|
101
|
+
for (const hook of group.hooks) {
|
|
102
|
+
if (hook.type === "command" && hook.command) {
|
|
103
|
+
const output = executeCommandHook(hook.command, pluginName, hook.timeout || 30000);
|
|
104
|
+
if (output && !output.startsWith("[Skipped:")) {
|
|
105
|
+
pluginOutputs.push(output);
|
|
106
|
+
}
|
|
107
|
+
}
|
|
108
|
+
else if (hook.type === "prompt" && hook.prompt) {
|
|
109
|
+
// Prompt hooks are output directly as context
|
|
110
|
+
pluginOutputs.push(hook.prompt);
|
|
111
|
+
}
|
|
112
|
+
}
|
|
113
|
+
}
|
|
114
|
+
return pluginOutputs.length > 0 ? pluginOutputs : null;
|
|
115
|
+
}));
|
|
116
|
+
// Collect all non-null outputs
|
|
117
|
+
for (const result of results) {
|
|
118
|
+
if (result) {
|
|
119
|
+
outputs.push(...result);
|
|
120
|
+
}
|
|
121
|
+
}
|
|
122
|
+
// Output aggregated results
|
|
123
|
+
if (outputs.length > 0) {
|
|
124
|
+
console.log(outputs.join("\n\n"));
|
|
125
|
+
}
|
|
126
|
+
}
|
|
127
|
+
export function registerHookDispatch(hookCommand) {
|
|
128
|
+
hookCommand
|
|
129
|
+
.command("dispatch <hookType>")
|
|
130
|
+
.description("Dispatch hooks of a specific type across all installed Han plugins.\n" +
|
|
131
|
+
"This is a workaround for Claude Code bug #12151 where plugin hook output\n" +
|
|
132
|
+
"is not passed to the agent. Add this to ~/.claude/settings.json:\n\n" +
|
|
133
|
+
' "hooks": {\n' +
|
|
134
|
+
' "UserPromptSubmit": [{"hooks": [{"type": "command",\n' +
|
|
135
|
+
' "command": "npx -y @thebushidocollective/han hook dispatch UserPromptSubmit"}]}],\n' +
|
|
136
|
+
' "SessionStart": [{"hooks": [{"type": "command",\n' +
|
|
137
|
+
' "command": "npx -y @thebushidocollective/han hook dispatch SessionStart"}]}]\n' +
|
|
138
|
+
" }")
|
|
139
|
+
.action(async (hookType) => {
|
|
140
|
+
await dispatchHooks(hookType);
|
|
141
|
+
});
|
|
142
|
+
}
|
|
143
|
+
//# sourceMappingURL=dispatch.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"dispatch.js","sourceRoot":"","sources":["../../../../lib/commands/hook/dispatch.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,oBAAoB,CAAC;AAE9C,OAAO,EACN,mBAAmB,EACnB,oBAAoB,GACpB,MAAM,iBAAiB,CAAC;AAoBzB;;GAEG;AACH,KAAK,UAAU,gBAAgB,CAAC,UAAkB;IACjD,mDAAmD;IACnD,IAAI,UAAkB,CAAC;IACvB,IAAI,UAAU,CAAC,UAAU,CAAC,QAAQ,CAAC,EAAE,CAAC;QACrC,UAAU,GAAG,SAAS,UAAU,EAAE,CAAC;IACpC,CAAC;SAAM,IAAI,UAAU,CAAC,UAAU,CAAC,KAAK,CAAC,EAAE,CAAC;QACzC,UAAU,GAAG,MAAM,UAAU,EAAE,CAAC;IACjC,CAAC;SAAM,IAAI,UAAU,CAAC,UAAU,CAAC,QAAQ,CAAC,EAAE,CAAC;QAC5C,UAAU,G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AC,MAAM,CAAC,CAAC,CAAC;IACnC,CAAC;AACF,CAAC;AAED,MAAM,UAAU,oBAAoB,CAAC,WAAoB;IACxD,WAAW;SACT,OAAO,CAAC,qBAAqB,CAAC;SAC9B,WAAW,CACX,uEAAuE;QACtE,4EAA4E;QAC5E,sEAAsE;QACtE,gBAAgB;QAChB,2DAA2D;QAC3D,2FAA2F;QAC3F,uDAAuD;QACvD,sFAAsF;QACtF,KAAK,CACN;SACA,MAAM,CAAC,KAAK,EAAE,QAAgB,EAAE,EAAE;QAClC,MAAM,aAAa,CAAC,QAAQ,CAAC,CAAC;IAC/B,CAAC,CAAC,CAAC;AACL,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../lib/commands/hook/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../lib/commands/hook/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAKzC;;GAEG;AACH,wBAAgB,oBAAoB,CAAC,OAAO,EAAE,OAAO,GAAG,IAAI,CAM3D"}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { registerHookDispatch } from "./dispatch.js";
|
|
1
2
|
import { registerHookRun } from "./run.js";
|
|
2
3
|
import { registerHookTest } from "./test.js";
|
|
3
4
|
/**
|
|
@@ -5,6 +6,7 @@ import { registerHookTest } from "./test.js";
|
|
|
5
6
|
*/
|
|
6
7
|
export function registerHookCommands(program) {
|
|
7
8
|
const hookCommand = program.command("hook").description("Hook utilities");
|
|
9
|
+
registerHookDispatch(hookCommand);
|
|
8
10
|
registerHookRun(hookCommand);
|
|
9
11
|
registerHookTest(hookCommand);
|
|
10
12
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../lib/commands/hook/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,eAAe,EAAE,MAAM,UAAU,CAAC;AAC3C,OAAO,EAAE,gBAAgB,EAAE,MAAM,WAAW,CAAC;AAE7C;;GAEG;AACH,MAAM,UAAU,oBAAoB,CAAC,OAAgB;IACpD,MAAM,WAAW,GAAG,OAAO,CAAC,OAAO,CAAC,MAAM,CAAC,CAAC,WAAW,CAAC,gBAAgB,CAAC,CAAC;IAE1E,eAAe,CAAC,WAAW,CAAC,CAAC;IAC7B,gBAAgB,CAAC,WAAW,CAAC,CAAC;AAC/B,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../lib/commands/hook/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,oBAAoB,EAAE,MAAM,eAAe,CAAC;AACrD,OAAO,EAAE,eAAe,EAAE,MAAM,UAAU,CAAC;AAC3C,OAAO,EAAE,gBAAgB,EAAE,MAAM,WAAW,CAAC;AAE7C;;GAEG;AACH,MAAM,UAAU,oBAAoB,CAAC,OAAgB;IACpD,MAAM,WAAW,GAAG,OAAO,CAAC,OAAO,CAAC,MAAM,CAAC,CAAC,WAAW,CAAC,gBAAgB,CAAC,CAAC;IAE1E,oBAAoB,CAAC,WAAW,CAAC,CAAC;IAClC,eAAe,CAAC,WAAW,CAAC,CAAC;IAC7B,gBAAgB,CAAC,WAAW,CAAC,CAAC;AAC/B,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@thebushidocollective/han",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.35.0",
|
|
4
4
|
"description": "CLI for installing and managing curated Claude Code plugins from the Han marketplace",
|
|
5
5
|
"main": "dist/lib/main.js",
|
|
6
6
|
"types": "dist/lib/main.d.ts",
|
|
@@ -51,11 +51,11 @@
|
|
|
51
51
|
"README.md"
|
|
52
52
|
],
|
|
53
53
|
"optionalDependencies": {
|
|
54
|
-
"@thebushidocollective/han-darwin-arm64": "1.
|
|
55
|
-
"@thebushidocollective/han-darwin-x64": "1.
|
|
56
|
-
"@thebushidocollective/han-linux-arm64": "1.
|
|
57
|
-
"@thebushidocollective/han-linux-x64": "1.
|
|
58
|
-
"@thebushidocollective/han-win32-x64": "1.
|
|
54
|
+
"@thebushidocollective/han-darwin-arm64": "1.35.0",
|
|
55
|
+
"@thebushidocollective/han-darwin-x64": "1.35.0",
|
|
56
|
+
"@thebushidocollective/han-linux-arm64": "1.35.0",
|
|
57
|
+
"@thebushidocollective/han-linux-x64": "1.35.0",
|
|
58
|
+
"@thebushidocollective/han-win32-x64": "1.35.0"
|
|
59
59
|
},
|
|
60
60
|
"devDependencies": {
|
|
61
61
|
"@anthropic-ai/claude-agent-sdk": "0.1.50",
|