@meltstudio/meltctl 4.5.4 → 4.6.1
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 +2 -2
- package/dist/commands/init.js +34 -6
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -34,8 +34,8 @@ meltctl version --check
|
|
|
34
34
|
|
|
35
35
|
- `AGENTS.md` — AI agent instructions and project standards
|
|
36
36
|
- `.claude/settings.json` — Claude Code permissions
|
|
37
|
-
- `.claude/skills/melt-{setup,plan,review,pr,debug}/SKILL.md` — Claude Code workflow skills
|
|
38
|
-
- `.cursor/commands/melt-{setup,plan,review,pr,debug}.md` — Cursor workflow commands
|
|
37
|
+
- `.claude/skills/melt-{setup,plan,review,pr,debug,audit}/SKILL.md` — Claude Code workflow skills
|
|
38
|
+
- `.cursor/commands/melt-{setup,plan,review,pr,debug,audit}.md` — Cursor workflow commands
|
|
39
39
|
- `.mcp.json` — MCP server configuration (Chrome DevTools)
|
|
40
40
|
|
|
41
41
|
## Requirements
|
package/dist/commands/init.js
CHANGED
|
@@ -33,6 +33,12 @@ user-invocable: true
|
|
|
33
33
|
description: Systematically investigate and fix bugs
|
|
34
34
|
---
|
|
35
35
|
|
|
36
|
+
`,
|
|
37
|
+
audit: `---
|
|
38
|
+
user-invocable: true
|
|
39
|
+
description: Run a project compliance audit against team standards
|
|
40
|
+
---
|
|
41
|
+
|
|
36
42
|
`,
|
|
37
43
|
};
|
|
38
44
|
const GITIGNORE_ENTRIES = ['.env.local', '.claude/settings.local.json'];
|
|
@@ -141,7 +147,7 @@ export async function initCommand(options) {
|
|
|
141
147
|
console.log(chalk.bold('Initializing Melt development tools...'));
|
|
142
148
|
console.log();
|
|
143
149
|
const createdFiles = [];
|
|
144
|
-
const workflows = ['setup', 'plan', 'review', 'pr', 'debug'];
|
|
150
|
+
const workflows = ['setup', 'plan', 'review', 'pr', 'debug', 'audit'];
|
|
145
151
|
// Shared files (skip on re-init)
|
|
146
152
|
if (!isReInit) {
|
|
147
153
|
const agentsMd = templates['agents-md.md'];
|
|
@@ -161,7 +167,7 @@ export async function initCommand(options) {
|
|
|
161
167
|
const claudeSettings = templates['claude-settings.json'];
|
|
162
168
|
if (claudeSettings) {
|
|
163
169
|
await fs.ensureDir(path.join(cwd, '.claude'));
|
|
164
|
-
await
|
|
170
|
+
await mergeClaudeSettings(cwd, claudeSettings);
|
|
165
171
|
createdFiles.push('.claude/settings.json');
|
|
166
172
|
}
|
|
167
173
|
for (const name of workflows) {
|
|
@@ -173,7 +179,7 @@ export async function initCommand(options) {
|
|
|
173
179
|
await fs.writeFile(path.join(skillDir, 'SKILL.md'), skillContent, 'utf-8');
|
|
174
180
|
}
|
|
175
181
|
}
|
|
176
|
-
createdFiles.push('.claude/skills/melt-{setup,plan,review,pr,debug}/SKILL.md');
|
|
182
|
+
createdFiles.push('.claude/skills/melt-{setup,plan,review,pr,debug,audit}/SKILL.md');
|
|
177
183
|
}
|
|
178
184
|
// Cursor files
|
|
179
185
|
if (tools.cursor) {
|
|
@@ -184,7 +190,7 @@ export async function initCommand(options) {
|
|
|
184
190
|
await fs.writeFile(path.join(cwd, `.cursor/commands/melt-${name}.md`), workflowContent, 'utf-8');
|
|
185
191
|
}
|
|
186
192
|
}
|
|
187
|
-
createdFiles.push('.cursor/commands/melt-{setup,plan,review,pr,debug}.md');
|
|
193
|
+
createdFiles.push('.cursor/commands/melt-{setup,plan,review,pr,debug,audit}.md');
|
|
188
194
|
}
|
|
189
195
|
// Print summary
|
|
190
196
|
console.log(chalk.green('Created files:'));
|
|
@@ -197,11 +203,11 @@ export async function initCommand(options) {
|
|
|
197
203
|
console.log();
|
|
198
204
|
}
|
|
199
205
|
if (tools.claude) {
|
|
200
|
-
const skills = '/melt-setup, /melt-plan, /melt-review, /melt-pr, /melt-debug';
|
|
206
|
+
const skills = '/melt-setup, /melt-plan, /melt-review, /melt-pr, /melt-debug, /melt-audit';
|
|
201
207
|
console.log(chalk.dim(`Available skills: ${skills}`));
|
|
202
208
|
}
|
|
203
209
|
if (tools.cursor) {
|
|
204
|
-
console.log(chalk.dim('Available commands: melt-setup, melt-plan, melt-review, melt-pr, melt-debug'));
|
|
210
|
+
console.log(chalk.dim('Available commands: melt-setup, melt-plan, melt-review, melt-pr, melt-debug, melt-audit'));
|
|
205
211
|
}
|
|
206
212
|
if (tools.claude || tools.cursor) {
|
|
207
213
|
console.log();
|
|
@@ -240,6 +246,28 @@ async function mergeMcpConfig(cwd, templateContent) {
|
|
|
240
246
|
await fs.writeFile(mcpPath, templateContent, 'utf-8');
|
|
241
247
|
}
|
|
242
248
|
}
|
|
249
|
+
async function mergeClaudeSettings(cwd, templateContent) {
|
|
250
|
+
const settingsPath = path.join(cwd, '.claude/settings.json');
|
|
251
|
+
const templateConfig = JSON.parse(templateContent);
|
|
252
|
+
if (await fs.pathExists(settingsPath)) {
|
|
253
|
+
const existingContent = await fs.readFile(settingsPath, 'utf-8');
|
|
254
|
+
const existingConfig = JSON.parse(existingContent);
|
|
255
|
+
// Merge permissions: combine allow/deny lists, deduplicate
|
|
256
|
+
const existingAllow = existingConfig.permissions?.allow ?? [];
|
|
257
|
+
const existingDeny = existingConfig.permissions?.deny ?? [];
|
|
258
|
+
const templateAllow = templateConfig.permissions?.allow ?? [];
|
|
259
|
+
const templateDeny = templateConfig.permissions?.deny ?? [];
|
|
260
|
+
existingConfig.permissions = {
|
|
261
|
+
...existingConfig.permissions,
|
|
262
|
+
allow: [...new Set([...existingAllow, ...templateAllow])],
|
|
263
|
+
deny: [...new Set([...existingDeny, ...templateDeny])],
|
|
264
|
+
};
|
|
265
|
+
await fs.writeFile(settingsPath, JSON.stringify(existingConfig, null, 2) + '\n', 'utf-8');
|
|
266
|
+
}
|
|
267
|
+
else {
|
|
268
|
+
await fs.writeFile(settingsPath, templateContent, 'utf-8');
|
|
269
|
+
}
|
|
270
|
+
}
|
|
243
271
|
async function updateGitignore(cwd) {
|
|
244
272
|
const gitignorePath = path.join(cwd, '.gitignore');
|
|
245
273
|
let content = '';
|
package/package.json
CHANGED