@voltui/agent 0.0.0-stage → 0.5.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/LICENSE +21 -0
- package/README.md +62 -2
- package/content.js +787 -0
- package/installer.js +440 -0
- package/package.json +39 -4
- package/setup-agent.js +9 -0
package/installer.js
ADDED
|
@@ -0,0 +1,440 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Volt UI agent setup (@voltui/agent)
|
|
3
|
+
*
|
|
4
|
+
* Configures AI agents to use the Volt UI MCP server and writes the Volt UI context files
|
|
5
|
+
* (skill, rules, snippets) into a project.
|
|
6
|
+
*
|
|
7
|
+
* Usage:
|
|
8
|
+
* npx @voltui/agent interactive
|
|
9
|
+
* npx @voltui/agent claude one agent
|
|
10
|
+
* npx @voltui/agent cursor copilot several agents
|
|
11
|
+
* npx @voltui/agent --all --yes every agent, no prompts
|
|
12
|
+
* npx @voltui/agent claude --dry-run show what would be written
|
|
13
|
+
* npx @voltui/agent claude --uninstall remove what the installer wrote
|
|
14
|
+
*
|
|
15
|
+
* Run `npx @voltui/agent --help` for every flag.
|
|
16
|
+
*
|
|
17
|
+
* Re-running is safe: JSON configs are merged, files shared with the user (rules, instructions) get
|
|
18
|
+
* a delimited block that is replaced in place, and files the installer owns are rewritten.
|
|
19
|
+
*/
|
|
20
|
+
|
|
21
|
+
'use strict';
|
|
22
|
+
|
|
23
|
+
const fs = require('fs');
|
|
24
|
+
const path = require('path');
|
|
25
|
+
const readline = require('readline');
|
|
26
|
+
const { DEFAULT_MCP_URL, buildContent } = require('./content');
|
|
27
|
+
|
|
28
|
+
const VERSION = require('./package.json').version;
|
|
29
|
+
|
|
30
|
+
const BLOCK_START =
|
|
31
|
+
'<!-- volt-ui:begin (managed by @voltui/agent — edits inside are overwritten) -->';
|
|
32
|
+
const BLOCK_END = '<!-- volt-ui:end -->';
|
|
33
|
+
|
|
34
|
+
// ---------------------------------------------------------------------------
|
|
35
|
+
// Agent plans
|
|
36
|
+
//
|
|
37
|
+
// An agent is a list of files. `kind` decides how an existing file is treated:
|
|
38
|
+
// json merged into the existing JSON (the user's other keys survive)
|
|
39
|
+
// block a delimited block inside a file the user also edits
|
|
40
|
+
// owned a file that is entirely Volt's (rewritten each run, deleted on uninstall)
|
|
41
|
+
// ---------------------------------------------------------------------------
|
|
42
|
+
|
|
43
|
+
function buildAgents(mcpUrl) {
|
|
44
|
+
const { CURSOR_RULES, COPILOT_INSTRUCTIONS, VOLT_UI_SKILL, VSCODE_SNIPPETS } =
|
|
45
|
+
buildContent(mcpUrl);
|
|
46
|
+
// Cursor / Windsurf accept a bare `url` entry; Claude Code's `.mcp.json` and VS Code's
|
|
47
|
+
// `.vscode/mcp.json` use the `http` transport type.
|
|
48
|
+
const urlEntry = { type: 'url', url: mcpUrl };
|
|
49
|
+
const httpEntry = { type: 'http', url: mcpUrl };
|
|
50
|
+
const snippets = {
|
|
51
|
+
path: '.vscode/volt-snippets.code-snippets',
|
|
52
|
+
kind: 'owned',
|
|
53
|
+
content: JSON.stringify(VSCODE_SNIPPETS, null, 2) + '\n',
|
|
54
|
+
};
|
|
55
|
+
|
|
56
|
+
return {
|
|
57
|
+
claude: {
|
|
58
|
+
label: 'Claude Code',
|
|
59
|
+
files: [
|
|
60
|
+
{
|
|
61
|
+
path: '.mcp.json',
|
|
62
|
+
kind: 'json',
|
|
63
|
+
content: { mcpServers: { 'volt-ui': httpEntry } },
|
|
64
|
+
owns: ['mcpServers', 'volt-ui'],
|
|
65
|
+
},
|
|
66
|
+
{ path: '.claude/skills/volt-ui/SKILL.md', kind: 'owned', content: VOLT_UI_SKILL },
|
|
67
|
+
],
|
|
68
|
+
notes: [
|
|
69
|
+
'Restart Claude Code for the MCP server and skill to load.',
|
|
70
|
+
'Claude Desktop: remote MCP servers are added via Settings -> Connectors, not by editing claude_desktop_config.json.',
|
|
71
|
+
],
|
|
72
|
+
},
|
|
73
|
+
cursor: {
|
|
74
|
+
label: 'Cursor',
|
|
75
|
+
files: [
|
|
76
|
+
{
|
|
77
|
+
path: '.cursor/mcp.json',
|
|
78
|
+
kind: 'json',
|
|
79
|
+
content: { mcpServers: { 'volt-ui': urlEntry } },
|
|
80
|
+
owns: ['mcpServers', 'volt-ui'],
|
|
81
|
+
},
|
|
82
|
+
{ path: '.cursorrules', kind: 'block', content: CURSOR_RULES },
|
|
83
|
+
],
|
|
84
|
+
notes: ['Restart Cursor for MCP changes to take effect.'],
|
|
85
|
+
},
|
|
86
|
+
windsurf: {
|
|
87
|
+
label: 'Windsurf',
|
|
88
|
+
files: [
|
|
89
|
+
{
|
|
90
|
+
path: '.codeium/windsurf/mcp_config.json',
|
|
91
|
+
kind: 'json',
|
|
92
|
+
content: { mcpServers: { 'volt-ui': urlEntry } },
|
|
93
|
+
owns: ['mcpServers', 'volt-ui'],
|
|
94
|
+
},
|
|
95
|
+
],
|
|
96
|
+
notes: ['Restart Windsurf for MCP changes to take effect.'],
|
|
97
|
+
},
|
|
98
|
+
copilot: {
|
|
99
|
+
label: 'GitHub Copilot (VS Code)',
|
|
100
|
+
files: [
|
|
101
|
+
{
|
|
102
|
+
path: '.vscode/mcp.json',
|
|
103
|
+
kind: 'json',
|
|
104
|
+
content: { servers: { 'volt-ui': httpEntry } },
|
|
105
|
+
owns: ['servers', 'volt-ui'],
|
|
106
|
+
},
|
|
107
|
+
{ path: '.github/copilot-instructions.md', kind: 'block', content: COPILOT_INSTRUCTIONS },
|
|
108
|
+
snippets,
|
|
109
|
+
],
|
|
110
|
+
notes: [
|
|
111
|
+
'Reload the VS Code window; start the volt-ui server from the MCP view if prompted.',
|
|
112
|
+
'The instructions file gives Copilot Chat context even where MCP is unavailable.',
|
|
113
|
+
],
|
|
114
|
+
},
|
|
115
|
+
vscode: {
|
|
116
|
+
label: 'VS Code (snippets)',
|
|
117
|
+
files: [snippets],
|
|
118
|
+
notes: [
|
|
119
|
+
'Type "volt-button", "volt-card", etc. and press Tab to expand.',
|
|
120
|
+
'Reload the VS Code window to activate snippets.',
|
|
121
|
+
],
|
|
122
|
+
},
|
|
123
|
+
};
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
// ---------------------------------------------------------------------------
|
|
127
|
+
// File operations — each returns a short status string and honours `dryRun`
|
|
128
|
+
// ---------------------------------------------------------------------------
|
|
129
|
+
|
|
130
|
+
function readIfExists(file) {
|
|
131
|
+
try {
|
|
132
|
+
return fs.readFileSync(file, 'utf-8');
|
|
133
|
+
} catch (err) {
|
|
134
|
+
if (err.code === 'ENOENT') return null;
|
|
135
|
+
throw err;
|
|
136
|
+
}
|
|
137
|
+
}
|
|
138
|
+
|
|
139
|
+
function write(file, text, dryRun) {
|
|
140
|
+
if (dryRun) return;
|
|
141
|
+
fs.mkdirSync(path.dirname(file), { recursive: true });
|
|
142
|
+
fs.writeFileSync(file, text);
|
|
143
|
+
}
|
|
144
|
+
|
|
145
|
+
function deepMerge(target, source) {
|
|
146
|
+
const out = { ...target };
|
|
147
|
+
for (const [key, value] of Object.entries(source)) {
|
|
148
|
+
const current = out[key];
|
|
149
|
+
out[key] =
|
|
150
|
+
value &&
|
|
151
|
+
typeof value === 'object' &&
|
|
152
|
+
!Array.isArray(value) &&
|
|
153
|
+
current &&
|
|
154
|
+
typeof current === 'object'
|
|
155
|
+
? deepMerge(current, value)
|
|
156
|
+
: value;
|
|
157
|
+
}
|
|
158
|
+
return out;
|
|
159
|
+
}
|
|
160
|
+
|
|
161
|
+
function parseJsonStrict(file, text) {
|
|
162
|
+
try {
|
|
163
|
+
return JSON.parse(text);
|
|
164
|
+
} catch {
|
|
165
|
+
// A config the user wrote by hand (comments, trailing commas) must never be overwritten.
|
|
166
|
+
throw new Error(
|
|
167
|
+
`${file} is not valid JSON, so it was left untouched. Fix or remove it, then re-run.`
|
|
168
|
+
);
|
|
169
|
+
}
|
|
170
|
+
}
|
|
171
|
+
|
|
172
|
+
function wrapBlock(content) {
|
|
173
|
+
return `${BLOCK_START}\n${content.trim()}\n${BLOCK_END}\n`;
|
|
174
|
+
}
|
|
175
|
+
|
|
176
|
+
function blockPattern() {
|
|
177
|
+
const esc = s => s.replace(/[.*+?^${}()|[\]\\]/g, '\\$&');
|
|
178
|
+
return new RegExp(`${esc(BLOCK_START)}[\\s\\S]*?${esc(BLOCK_END)}\\n?`);
|
|
179
|
+
}
|
|
180
|
+
|
|
181
|
+
function install(file, spec, dryRun) {
|
|
182
|
+
const existing = readIfExists(file);
|
|
183
|
+
|
|
184
|
+
if (spec.kind === 'json') {
|
|
185
|
+
const merged =
|
|
186
|
+
existing === null ? spec.content : deepMerge(parseJsonStrict(file, existing), spec.content);
|
|
187
|
+
const next = JSON.stringify(merged, null, 2) + '\n';
|
|
188
|
+
if (existing === next) return 'unchanged';
|
|
189
|
+
write(file, next, dryRun);
|
|
190
|
+
return existing === null ? 'created' : 'updated';
|
|
191
|
+
}
|
|
192
|
+
|
|
193
|
+
if (spec.kind === 'block') {
|
|
194
|
+
const block = wrapBlock(spec.content);
|
|
195
|
+
let next;
|
|
196
|
+
if (existing === null) next = block;
|
|
197
|
+
else if (blockPattern().test(existing)) next = existing.replace(blockPattern(), () => block);
|
|
198
|
+
else next = existing.replace(/\s*$/, '\n\n') + block;
|
|
199
|
+
if (existing === next) return 'unchanged';
|
|
200
|
+
write(file, next, dryRun);
|
|
201
|
+
return existing === null ? 'created' : 'updated';
|
|
202
|
+
}
|
|
203
|
+
|
|
204
|
+
// owned
|
|
205
|
+
if (existing === spec.content) return 'unchanged';
|
|
206
|
+
write(file, spec.content, dryRun);
|
|
207
|
+
return existing === null ? 'created' : 'updated';
|
|
208
|
+
}
|
|
209
|
+
|
|
210
|
+
function uninstall(file, spec, dryRun) {
|
|
211
|
+
const existing = readIfExists(file);
|
|
212
|
+
if (existing === null) return 'absent';
|
|
213
|
+
|
|
214
|
+
if (spec.kind === 'json') {
|
|
215
|
+
const json = parseJsonStrict(file, existing);
|
|
216
|
+
const [group, key] = spec.owns;
|
|
217
|
+
if (!json[group] || !(key in json[group])) return 'absent';
|
|
218
|
+
delete json[group][key];
|
|
219
|
+
if (!Object.keys(json[group]).length) delete json[group];
|
|
220
|
+
if (!dryRun) {
|
|
221
|
+
if (Object.keys(json).length) write(file, JSON.stringify(json, null, 2) + '\n', false);
|
|
222
|
+
else fs.rmSync(file);
|
|
223
|
+
}
|
|
224
|
+
return 'removed';
|
|
225
|
+
}
|
|
226
|
+
|
|
227
|
+
if (spec.kind === 'block') {
|
|
228
|
+
if (!blockPattern().test(existing)) return 'absent';
|
|
229
|
+
const next = existing
|
|
230
|
+
.replace(blockPattern(), '')
|
|
231
|
+
.replace(/\n{3,}/g, '\n\n')
|
|
232
|
+
.trim();
|
|
233
|
+
if (!dryRun) {
|
|
234
|
+
if (next) write(file, next + '\n', false);
|
|
235
|
+
else fs.rmSync(file);
|
|
236
|
+
}
|
|
237
|
+
return 'removed';
|
|
238
|
+
}
|
|
239
|
+
|
|
240
|
+
if (!dryRun) fs.rmSync(file);
|
|
241
|
+
return 'removed';
|
|
242
|
+
}
|
|
243
|
+
|
|
244
|
+
// ---------------------------------------------------------------------------
|
|
245
|
+
// Arguments
|
|
246
|
+
// ---------------------------------------------------------------------------
|
|
247
|
+
|
|
248
|
+
const HELP = `Volt UI agent setup (@voltui/agent ${VERSION})
|
|
249
|
+
|
|
250
|
+
Usage: npx @voltui/agent [agent...] [options]
|
|
251
|
+
|
|
252
|
+
Agents: claude, cursor, windsurf, copilot, vscode
|
|
253
|
+
With no agent and no --all, you are asked which to set up.
|
|
254
|
+
|
|
255
|
+
Options:
|
|
256
|
+
--all set up every agent
|
|
257
|
+
--dir <path> project directory (default: current directory)
|
|
258
|
+
--url <url> MCP endpoint to write (default: ${DEFAULT_MCP_URL})
|
|
259
|
+
--dry-run print what would change, write nothing
|
|
260
|
+
--uninstall remove what this installer wrote (your other config is kept)
|
|
261
|
+
-y, --yes never prompt; with no agent given, set up every agent
|
|
262
|
+
-v, --version print the version
|
|
263
|
+
-h, --help print this help
|
|
264
|
+
|
|
265
|
+
Exit codes: 0 ok · 1 failed · 2 bad usage`;
|
|
266
|
+
|
|
267
|
+
class UsageError extends Error {}
|
|
268
|
+
|
|
269
|
+
function parseArgs(argv, agentKeys) {
|
|
270
|
+
const opts = {
|
|
271
|
+
agents: [],
|
|
272
|
+
all: false,
|
|
273
|
+
dir: null,
|
|
274
|
+
url: DEFAULT_MCP_URL,
|
|
275
|
+
dryRun: false,
|
|
276
|
+
uninstall: false,
|
|
277
|
+
yes: false,
|
|
278
|
+
help: false,
|
|
279
|
+
version: false,
|
|
280
|
+
};
|
|
281
|
+
const value = (i, flag) => {
|
|
282
|
+
if (i + 1 >= argv.length || argv[i + 1].startsWith('-')) {
|
|
283
|
+
throw new UsageError(`${flag} needs a value.`);
|
|
284
|
+
}
|
|
285
|
+
return argv[i + 1];
|
|
286
|
+
};
|
|
287
|
+
|
|
288
|
+
for (let i = 0; i < argv.length; i++) {
|
|
289
|
+
const arg = argv[i];
|
|
290
|
+
const eq = arg.startsWith('--') ? arg.indexOf('=') : -1;
|
|
291
|
+
const flag = eq === -1 ? arg : arg.slice(0, eq);
|
|
292
|
+
const inline = eq === -1 ? null : arg.slice(eq + 1);
|
|
293
|
+
const next = name => {
|
|
294
|
+
if (inline !== null) return inline;
|
|
295
|
+
const v = value(i, name);
|
|
296
|
+
i++;
|
|
297
|
+
return v;
|
|
298
|
+
};
|
|
299
|
+
|
|
300
|
+
if (flag === '--all') opts.all = true;
|
|
301
|
+
else if (flag === '--dry-run') opts.dryRun = true;
|
|
302
|
+
else if (flag === '--uninstall') opts.uninstall = true;
|
|
303
|
+
else if (flag === '-y' || flag === '--yes') opts.yes = true;
|
|
304
|
+
else if (flag === '-h' || flag === '--help') opts.help = true;
|
|
305
|
+
else if (flag === '-v' || flag === '--version') opts.version = true;
|
|
306
|
+
else if (flag === '--dir') opts.dir = next('--dir');
|
|
307
|
+
else if (flag === '--url') opts.url = next('--url');
|
|
308
|
+
else if (arg.startsWith('-')) throw new UsageError(`Unknown option: ${arg}`);
|
|
309
|
+
else if (agentKeys.includes(arg)) opts.agents.push(arg);
|
|
310
|
+
else throw new UsageError(`Unknown agent: ${arg}. Available: ${agentKeys.join(', ')}.`);
|
|
311
|
+
}
|
|
312
|
+
|
|
313
|
+
if (opts.all && opts.agents.length) {
|
|
314
|
+
throw new UsageError('Pass either agent names or --all, not both.');
|
|
315
|
+
}
|
|
316
|
+
try {
|
|
317
|
+
const u = new URL(opts.url);
|
|
318
|
+
if (u.protocol !== 'https:' && u.protocol !== 'http:') throw new Error();
|
|
319
|
+
} catch {
|
|
320
|
+
throw new UsageError(`--url must be an http(s) URL, got: ${opts.url}`);
|
|
321
|
+
}
|
|
322
|
+
opts.agents = [...new Set(opts.agents)];
|
|
323
|
+
return opts;
|
|
324
|
+
}
|
|
325
|
+
|
|
326
|
+
// ---------------------------------------------------------------------------
|
|
327
|
+
// Interactive prompts
|
|
328
|
+
// ---------------------------------------------------------------------------
|
|
329
|
+
|
|
330
|
+
const ask = (rl, question) => new Promise(resolve => rl.question(question, resolve));
|
|
331
|
+
|
|
332
|
+
async function promptAgents(rl, agents, out) {
|
|
333
|
+
const keys = Object.keys(agents);
|
|
334
|
+
out.log('\nAvailable agents:\n');
|
|
335
|
+
keys.forEach((key, i) => out.log(` ${i + 1}. ${agents[key].label} (${key})`));
|
|
336
|
+
out.log(' a. All of the above\n');
|
|
337
|
+
|
|
338
|
+
const answer = (
|
|
339
|
+
await ask(rl, `Select agent(s) [1-${keys.length}, comma-separated, or "a" for all]: `)
|
|
340
|
+
)
|
|
341
|
+
.trim()
|
|
342
|
+
.toLowerCase();
|
|
343
|
+
if (!answer || answer === 'a' || answer === 'all') return keys;
|
|
344
|
+
|
|
345
|
+
const picked = answer.split(/[,\s]+/).map(token => {
|
|
346
|
+
const n = parseInt(token, 10);
|
|
347
|
+
if (n >= 1 && n <= keys.length) return keys[n - 1];
|
|
348
|
+
if (agents[token]) return token;
|
|
349
|
+
throw new UsageError(`Not an agent: "${token}".`);
|
|
350
|
+
});
|
|
351
|
+
return [...new Set(picked)];
|
|
352
|
+
}
|
|
353
|
+
|
|
354
|
+
// ---------------------------------------------------------------------------
|
|
355
|
+
// Entry point
|
|
356
|
+
// ---------------------------------------------------------------------------
|
|
357
|
+
|
|
358
|
+
/**
|
|
359
|
+
* @param {string[]} argv arguments after the program name
|
|
360
|
+
* @param {{ cwd?: string, stdin?: NodeJS.ReadableStream, stdout?: NodeJS.WritableStream, isTTY?: boolean }} [env] injectable for tests
|
|
361
|
+
* @returns {Promise<number>} the exit code
|
|
362
|
+
*/
|
|
363
|
+
async function run(argv, env = {}) {
|
|
364
|
+
const cwd = env.cwd ?? process.cwd();
|
|
365
|
+
const out = { log: msg => console.log(msg) };
|
|
366
|
+
const isTTY = env.isTTY ?? Boolean(process.stdin.isTTY);
|
|
367
|
+
|
|
368
|
+
try {
|
|
369
|
+
const baseAgents = buildAgents(DEFAULT_MCP_URL);
|
|
370
|
+
const opts = parseArgs(argv, Object.keys(baseAgents));
|
|
371
|
+
|
|
372
|
+
if (opts.help || opts.version) {
|
|
373
|
+
out.log(opts.help ? HELP : VERSION);
|
|
374
|
+
return 0;
|
|
375
|
+
}
|
|
376
|
+
|
|
377
|
+
const agents = buildAgents(opts.url);
|
|
378
|
+
let selected = opts.all ? Object.keys(agents) : opts.agents;
|
|
379
|
+
let projectDir = opts.dir ? path.resolve(cwd, opts.dir) : cwd;
|
|
380
|
+
|
|
381
|
+
if (!selected.length) {
|
|
382
|
+
if (opts.yes) selected = Object.keys(agents);
|
|
383
|
+
else if (!isTTY) {
|
|
384
|
+
throw new UsageError('No agent given and no terminal to ask on. Pass an agent or --all.');
|
|
385
|
+
} else {
|
|
386
|
+
const rl = readline.createInterface({
|
|
387
|
+
input: env.stdin ?? process.stdin,
|
|
388
|
+
output: env.stdout ?? process.stdout,
|
|
389
|
+
});
|
|
390
|
+
try {
|
|
391
|
+
selected = await promptAgents(rl, agents, out);
|
|
392
|
+
if (!opts.dir) {
|
|
393
|
+
const dir = (await ask(rl, `\nProject directory [${projectDir}]: `)).trim();
|
|
394
|
+
if (dir) projectDir = path.resolve(cwd, dir);
|
|
395
|
+
}
|
|
396
|
+
} finally {
|
|
397
|
+
rl.close();
|
|
398
|
+
}
|
|
399
|
+
}
|
|
400
|
+
}
|
|
401
|
+
|
|
402
|
+
if (!fs.existsSync(projectDir) || !fs.statSync(projectDir).isDirectory()) {
|
|
403
|
+
throw new UsageError(`Project directory does not exist: ${projectDir}`);
|
|
404
|
+
}
|
|
405
|
+
|
|
406
|
+
const verb = opts.uninstall ? 'Removing from' : 'Setting up';
|
|
407
|
+
out.log(`${verb}: ${projectDir}${opts.dryRun ? ' (dry run — nothing is written)' : ''}`);
|
|
408
|
+
if (!opts.uninstall) out.log(`MCP endpoint: ${opts.url}`);
|
|
409
|
+
|
|
410
|
+
for (const key of selected) {
|
|
411
|
+
const agent = agents[key];
|
|
412
|
+
out.log(`\n${agent.label}`);
|
|
413
|
+
for (const spec of agent.files) {
|
|
414
|
+
const file = path.join(projectDir, spec.path);
|
|
415
|
+
const status = opts.uninstall
|
|
416
|
+
? uninstall(file, spec, opts.dryRun)
|
|
417
|
+
: install(file, spec, opts.dryRun);
|
|
418
|
+
out.log(` ${status.padEnd(9)} ${spec.path}`);
|
|
419
|
+
}
|
|
420
|
+
if (!opts.uninstall) agent.notes.forEach(note => out.log(` → ${note}`));
|
|
421
|
+
}
|
|
422
|
+
|
|
423
|
+
if (!opts.uninstall && !opts.dryRun) {
|
|
424
|
+
out.log('\nDone. Next steps:');
|
|
425
|
+
out.log(' npx @voltui/cli init scaffold the ui/ folder');
|
|
426
|
+
out.log(' npx @voltui/cli add button add a component');
|
|
427
|
+
out.log(' npx @voltui/cli list list every component');
|
|
428
|
+
}
|
|
429
|
+
return 0;
|
|
430
|
+
} catch (err) {
|
|
431
|
+
if (err instanceof UsageError) {
|
|
432
|
+
console.error(`Error: ${err.message}\n\nRun with --help for usage.`);
|
|
433
|
+
return 2;
|
|
434
|
+
}
|
|
435
|
+
console.error(`Error: ${err.message}`);
|
|
436
|
+
return 1;
|
|
437
|
+
}
|
|
438
|
+
}
|
|
439
|
+
|
|
440
|
+
module.exports = { run, buildAgents, parseArgs, BLOCK_START, BLOCK_END };
|
package/package.json
CHANGED
|
@@ -1,6 +1,41 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@voltui/agent",
|
|
3
|
-
"version": "0.
|
|
4
|
-
"
|
|
5
|
-
"
|
|
6
|
-
|
|
3
|
+
"version": "0.5.0",
|
|
4
|
+
"description": "Set up Volt UI for AI coding agents: the MCP server, skill and rules for Claude Code, Cursor, Windsurf and GitHub Copilot",
|
|
5
|
+
"homepage": "https://volt-ui.andersseen.dev/docs/ai-mcp",
|
|
6
|
+
"repository": {
|
|
7
|
+
"type": "git",
|
|
8
|
+
"url": "git+https://github.com/Andersseen/volt-ui.git",
|
|
9
|
+
"directory": "cli/agent"
|
|
10
|
+
},
|
|
11
|
+
"bugs": {
|
|
12
|
+
"url": "https://github.com/Andersseen/volt-ui/issues"
|
|
13
|
+
},
|
|
14
|
+
"bin": {
|
|
15
|
+
"volt-ui-agent": "setup-agent.js"
|
|
16
|
+
},
|
|
17
|
+
"files": [
|
|
18
|
+
"setup-agent.js",
|
|
19
|
+
"installer.js",
|
|
20
|
+
"content.js",
|
|
21
|
+
"README.md",
|
|
22
|
+
"LICENSE"
|
|
23
|
+
],
|
|
24
|
+
"keywords": [
|
|
25
|
+
"mcp",
|
|
26
|
+
"model-context-protocol",
|
|
27
|
+
"angular",
|
|
28
|
+
"volt-ui",
|
|
29
|
+
"claude",
|
|
30
|
+
"cursor",
|
|
31
|
+
"windsurf",
|
|
32
|
+
"copilot",
|
|
33
|
+
"ai",
|
|
34
|
+
"skills",
|
|
35
|
+
"agent"
|
|
36
|
+
],
|
|
37
|
+
"license": "MIT",
|
|
38
|
+
"engines": {
|
|
39
|
+
"node": ">=20"
|
|
40
|
+
}
|
|
41
|
+
}
|