ironweave 1.1.6 → 1.1.7

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/README.md CHANGED
@@ -98,33 +98,60 @@ User Request
98
98
 
99
99
  ## Installation
100
100
 
101
- ### Via skills.sh (Recommended)
101
+ ### Via npm
102
102
 
103
103
  ```bash
104
- # Install all skills at once (no prompts)
105
- npx skills add YuluoY/ironware --all
104
+ # Install all skills + all agent configs (Chinese, default)
105
+ npx ironweave@latest init
106
106
 
107
- # Interactive: select which skills to install
108
- npx skills add YuluoY/ironware
107
+ # Install English skills
108
+ npx ironweave@latest init --lang en
109
109
 
110
- # Install specific skills only
111
- npx skills add YuluoY/ironware --skill orchestrator --skill brainstorm
110
+ # Install for a specific editor only
111
+ npx ironweave@latest init --agent cursor
112
+ npx ironweave@latest init --agent trae
113
+ npx ironweave@latest init --agent windsurf
112
114
 
113
- # List available skills
114
- npx skills add YuluoY/ironware --list
115
+ # Only copy skills, skip agent config files
116
+ npx ironweave@latest init --skills-only
117
+
118
+ # Overwrite existing files
119
+ npx ironweave@latest init --force
120
+
121
+ # List all available skills
122
+ npx ironweave@latest list
115
123
  ```
116
124
 
117
- Or via npm (supports `--lang en` for English skills):
125
+ Available agents: `claude`, `copilot`, `cursor`, `windsurf`, `cline`, `trae`, `codebuddy`, `codex`, `gemini`, `all` (default).
126
+
127
+ > **Conflict handling**: Existing files are preserved by default. Ironweave adds its config alongside your existing rules. Use `--force` to overwrite.
128
+
129
+ > **Skills location**: When targeting a single directory-based editor (e.g., `--agent trae`), skills are installed inside the editor directory (e.g., `.trae/skills/`). With `--agent all` (default), skills go to the project root `skills/`.
130
+
131
+ ### Via skills.sh
118
132
 
119
133
  ```bash
120
- # Install with Chinese skills (default)
121
- npx ironweave init
134
+ # Install to a specific editor (recommended)
135
+ npx skills add YuluoY/ironware --skill '*' -a cursor -y
136
+ npx skills add YuluoY/ironware --skill '*' -a trae -y
137
+ npx skills add YuluoY/ironware --skill '*' -a claude-code -y
122
138
 
123
- # Install with English skills
124
- npx ironweave init --lang en
139
+ # Install to multiple editors
140
+ npx skills add YuluoY/ironware --skill '*' -a cursor -a windsurf -y
141
+
142
+ # Install to ALL editors (installs many agent directories)
143
+ npx skills add YuluoY/ironware --all
144
+
145
+ # Interactive: select skills and editors
146
+ npx skills add YuluoY/ironware
147
+
148
+ # List available skills
149
+ npx skills add YuluoY/ironware --list
125
150
  ```
126
151
 
127
- Supports **9 agents**: Claude Code, GitHub Copilot, Cursor, Windsurf, Cline, Trae, CodeBuddy, Codex, Gemini CLI.
152
+ Agent names for skills.sh: `claude-code`, `github-copilot`, `cursor`, `windsurf`, `cline`, `trae`, `codebuddy`, `codex`, `gemini-cli`.
153
+
154
+ > Note: `skills.sh` does not support `--lang`. For English skills, use `npx ironweave@latest init --lang en`.
128
155
 
129
156
  ### Per-Agent Manual Installation
130
157
 
package/README_CN.md CHANGED
@@ -96,33 +96,60 @@ Ironweave 是一套完整的软件开发工作流,由一组可自由组合的
96
96
 
97
97
  ## 安装
98
98
 
99
- ### 通过 skills.sh(推荐)
99
+ ### 通过 npm
100
100
 
101
101
  ```bash
102
- # 一键安装全部技能(无交互提示)
103
- npx skills add YuluoY/ironware --all
102
+ # 安装全部技能 + 全部编辑器配置(中文,默认)
103
+ npx ironweave@latest init
104
104
 
105
- # 交互式选择要安装的技能
106
- npx skills add YuluoY/ironware
105
+ # 安装英文版技能
106
+ npx ironweave@latest init --lang en
107
107
 
108
- # 安装指定技能
109
- npx skills add YuluoY/ironware --skill orchestrator --skill brainstorm
108
+ # 只安装特定编辑器的配置
109
+ npx ironweave@latest init --agent cursor
110
+ npx ironweave@latest init --agent trae
111
+ npx ironweave@latest init --agent windsurf
110
112
 
111
- # 列出可用技能
112
- npx skills add YuluoY/ironware --list
113
+ # 只复制 skills/,不安装编辑器配置
114
+ npx ironweave@latest init --skills-only
115
+
116
+ # 覆盖已有文件
117
+ npx ironweave@latest init --force
118
+
119
+ # 列出所有可用技能
120
+ npx ironweave@latest list
113
121
  ```
114
122
 
115
- 或通过 npm 安装(支持 `--lang en` 切换英文版):
123
+ 可选编辑器:`claude`、`copilot`、`cursor`、`windsurf`、`cline`、`trae`、`codebuddy`、`codex`、`gemini`、`all`(默认全部)。
124
+
125
+ > **冲突处理**:默认不覆盖已有文件。Ironweave 会将配置与你现有的规则并存。使用 `--force` 强制覆盖。
126
+
127
+ > **Skills 位置**:指定单个目录型编辑器时(如 `--agent trae`),skills 会安装到该编辑器目录内(如 `.trae/skills/`)。使用 `--agent all`(默认)时,skills 安装在项目根目录 `skills/`。
128
+
129
+ ### 通过 skills.sh
116
130
 
117
131
  ```bash
118
- # 安装中文技能(默认)
119
- npx ironweave init
132
+ # 安装到指定编辑器(推荐)
133
+ npx skills add YuluoY/ironware --skill '*' -a cursor -y
134
+ npx skills add YuluoY/ironware --skill '*' -a trae -y
135
+ npx skills add YuluoY/ironware --skill '*' -a claude-code -y
120
136
 
121
- # 安装英文版技能
122
- npx ironweave init --lang en
137
+ # 安装到多个编辑器
138
+ npx skills add YuluoY/ironware --skill '*' -a cursor -a windsurf -y
139
+
140
+ # 安装到所有编辑器(会生成很多 agent 目录)
141
+ npx skills add YuluoY/ironware --all
142
+
143
+ # 交互式选择技能和编辑器
144
+ npx skills add YuluoY/ironware
145
+
146
+ # 列出可用技能
147
+ npx skills add YuluoY/ironware --list
123
148
  ```
124
149
 
125
- 支持 **9 Agent**:Claude Code、GitHub Copilot、Cursor、Windsurf、Cline、Trae、CodeBuddy、Codex、Gemini CLI。
150
+ skills.sh Agent 名称:`claude-code`、`github-copilot`、`cursor`、`windsurf`、`cline`、`trae`、`codebuddy`、`codex`、`gemini-cli`。
151
+
152
+ > 注意:`skills.sh` 不支持 `--lang` 参数。如需英文版,请使用 `npx ironweave@latest init --lang en`。
126
153
 
127
154
  ### 各 Agent 手动安装
128
155
 
package/bin/cli.js CHANGED
@@ -51,12 +51,25 @@ if (command === 'init') {
51
51
  const skillsOnly = args.includes('--skills-only');
52
52
  const force = args.includes('--force');
53
53
 
54
- // Copy skills/ and hooks/
54
+ // Directory-based agent roots (skills go inside agent dir for single-agent install)
55
+ const dirBasedAgents = {
56
+ cursor: '.cursor',
57
+ windsurf: '.windsurf',
58
+ cline: '.clinerules',
59
+ trae: '.trae',
60
+ codebuddy: '.codebuddy'
61
+ };
62
+ const isSingleDirAgent = agent !== 'all' && dirBasedAgents[agent];
63
+
64
+ // Copy skills/
55
65
  const skillsSrc = lang === 'en' ? 'skills-en' : 'skills';
56
66
  const srcSkills = path.join(pkgDir, skillsSrc);
57
- const dstSkills = path.join(targetDir, 'skills');
67
+ const dstSkills = isSingleDirAgent
68
+ ? path.join(targetDir, dirBasedAgents[agent], 'skills')
69
+ : path.join(targetDir, 'skills');
58
70
  copyDirRecursive(srcSkills, dstSkills, force);
59
- console.log(`✓ skills/ copied (${lang === 'en' ? 'English' : 'Chinese'})`);
71
+ const skillsLabel = isSingleDirAgent ? `${dirBasedAgents[agent]}/skills/` : 'skills/';
72
+ console.log(`✓ ${skillsLabel} copied (${lang === 'en' ? 'English' : 'Chinese'})`);
60
73
 
61
74
  const srcHooks = path.join(pkgDir, 'hooks');
62
75
  const dstHooks = path.join(targetDir, 'hooks');
@@ -115,6 +128,18 @@ if (command === 'init') {
115
128
  }
116
129
  }
117
130
  });
131
+ // Patch skills path references for single dir-based agent
132
+ if (isSingleDirAgent) {
133
+ const prefix = dirBasedAgents[agent] + '/';
134
+ files.forEach(f => {
135
+ const dstPath = path.join(targetDir, f.dst);
136
+ if (f.dir) {
137
+ patchSkillsPathsInDir(dstPath, prefix);
138
+ } else if (fs.existsSync(dstPath)) {
139
+ patchSkillsPathsInFile(dstPath, prefix);
140
+ }
141
+ });
142
+ }
118
143
  console.log(`✓ ${a} config installed`);
119
144
  });
120
145
  }
@@ -140,3 +165,18 @@ function copyDirRecursive(src, dst, force) {
140
165
  }
141
166
  }
142
167
  }
168
+
169
+ function patchSkillsPathsInDir(dirPath, prefix) {
170
+ if (!fs.existsSync(dirPath) || !fs.statSync(dirPath).isDirectory()) return;
171
+ for (const entry of fs.readdirSync(dirPath, { withFileTypes: true })) {
172
+ const full = path.join(dirPath, entry.name);
173
+ if (entry.isDirectory()) patchSkillsPathsInDir(full, prefix);
174
+ else patchSkillsPathsInFile(full, prefix);
175
+ }
176
+ }
177
+
178
+ function patchSkillsPathsInFile(filePath, prefix) {
179
+ let content = fs.readFileSync(filePath, 'utf8');
180
+ const patched = content.replace(/`skills\//g, '`' + prefix + 'skills/');
181
+ if (patched !== content) fs.writeFileSync(filePath, patched);
182
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ironweave",
3
- "version": "1.1.6",
3
+ "version": "1.1.7",
4
4
  "description": "Agentic skills framework for AI coding agents — orchestrated workflows with adaptive routing, quality gates, and 17 composable skills.",
5
5
  "keywords": [
6
6
  "agent-skills",