assistant-ui 0.0.19 → 0.0.20
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/index.js +41 -182
- package/dist/index.js.map +1 -1
- package/package.json +5 -7
package/dist/index.js
CHANGED
|
@@ -1,196 +1,24 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
|
|
3
|
-
// src/commands/add.ts
|
|
4
|
-
import { existsSync, mkdirSync } from "node:fs";
|
|
5
|
-
import path3 from "node:path";
|
|
6
|
-
import chalk from "chalk";
|
|
7
|
-
import { Command } from "commander";
|
|
8
|
-
import { spawn } from "cross-spawn";
|
|
9
|
-
|
|
10
|
-
// src/utils/get-component-target-path.ts
|
|
11
|
-
import path from "node:path";
|
|
12
|
-
function getComponentTargetPath(config) {
|
|
13
|
-
if (config.aliases.ui) {
|
|
14
|
-
return config.resolvedPaths.ui;
|
|
15
|
-
}
|
|
16
|
-
const [parent, type] = ["components", "ui"];
|
|
17
|
-
if (!(parent in config.resolvedPaths)) {
|
|
18
|
-
return null;
|
|
19
|
-
}
|
|
20
|
-
return path.join(
|
|
21
|
-
config.resolvedPaths[parent],
|
|
22
|
-
type
|
|
23
|
-
);
|
|
24
|
-
}
|
|
25
|
-
|
|
26
|
-
// src/utils/get-config.ts
|
|
27
|
-
import path2 from "node:path";
|
|
28
|
-
import { cosmiconfig } from "cosmiconfig";
|
|
29
|
-
import { loadConfig } from "tsconfig-paths";
|
|
30
|
-
import { z } from "zod";
|
|
31
|
-
|
|
32
|
-
// src/utils/resolve-import.ts
|
|
33
|
-
import {
|
|
34
|
-
createMatchPath
|
|
35
|
-
} from "tsconfig-paths";
|
|
36
|
-
function resolveImport(importPath, config) {
|
|
37
|
-
return createMatchPath(config.absoluteBaseUrl, config.paths)(
|
|
38
|
-
importPath,
|
|
39
|
-
void 0,
|
|
40
|
-
() => true,
|
|
41
|
-
[".ts", ".tsx"]
|
|
42
|
-
);
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
// src/utils/get-config.ts
|
|
46
|
-
var explorer = cosmiconfig("components", {
|
|
47
|
-
searchPlaces: ["components.json"]
|
|
48
|
-
});
|
|
49
|
-
var rawConfigSchema = z.object({
|
|
50
|
-
$schema: z.string().optional(),
|
|
51
|
-
style: z.string(),
|
|
52
|
-
rsc: z.coerce.boolean().default(false),
|
|
53
|
-
tsx: z.coerce.boolean().default(true),
|
|
54
|
-
tailwind: z.object({
|
|
55
|
-
config: z.string(),
|
|
56
|
-
css: z.string(),
|
|
57
|
-
baseColor: z.string(),
|
|
58
|
-
cssVariables: z.boolean().default(true),
|
|
59
|
-
prefix: z.string().default("").optional()
|
|
60
|
-
}),
|
|
61
|
-
aliases: z.object({
|
|
62
|
-
components: z.string(),
|
|
63
|
-
utils: z.string(),
|
|
64
|
-
ui: z.string().optional()
|
|
65
|
-
})
|
|
66
|
-
});
|
|
67
|
-
var configSchema = rawConfigSchema.extend({
|
|
68
|
-
resolvedPaths: z.object({
|
|
69
|
-
tailwindConfig: z.string(),
|
|
70
|
-
tailwindCss: z.string(),
|
|
71
|
-
utils: z.string(),
|
|
72
|
-
components: z.string(),
|
|
73
|
-
ui: z.string()
|
|
74
|
-
})
|
|
75
|
-
});
|
|
76
|
-
async function getConfig(cwd) {
|
|
77
|
-
const config = await getRawConfig(cwd);
|
|
78
|
-
if (!config) {
|
|
79
|
-
return null;
|
|
80
|
-
}
|
|
81
|
-
return resolveConfigPaths(cwd, config);
|
|
82
|
-
}
|
|
83
|
-
function resolveConfigPaths(cwd, config) {
|
|
84
|
-
const tsConfig = loadConfig(cwd);
|
|
85
|
-
if (tsConfig.resultType === "failed") {
|
|
86
|
-
throw new Error(
|
|
87
|
-
`Failed to load ${config.tsx ? "tsconfig" : "jsconfig"}.json. ${tsConfig.message ?? ""}`.trim()
|
|
88
|
-
);
|
|
89
|
-
}
|
|
90
|
-
return configSchema.parse({
|
|
91
|
-
...config,
|
|
92
|
-
resolvedPaths: {
|
|
93
|
-
tailwindConfig: path2.resolve(cwd, config.tailwind.config),
|
|
94
|
-
tailwindCss: path2.resolve(cwd, config.tailwind.css),
|
|
95
|
-
utils: resolveImport(config.aliases["utils"], tsConfig),
|
|
96
|
-
components: resolveImport(config.aliases["components"], tsConfig),
|
|
97
|
-
ui: config.aliases["ui"] ? resolveImport(config.aliases["ui"], tsConfig) : resolveImport(config.aliases["components"], tsConfig)
|
|
98
|
-
}
|
|
99
|
-
});
|
|
100
|
-
}
|
|
101
|
-
async function getRawConfig(cwd) {
|
|
102
|
-
try {
|
|
103
|
-
const configResult = await explorer.search(cwd);
|
|
104
|
-
if (!configResult) {
|
|
105
|
-
return null;
|
|
106
|
-
}
|
|
107
|
-
return rawConfigSchema.parse(configResult.config);
|
|
108
|
-
} catch (error) {
|
|
109
|
-
throw new Error(`Invalid configuration found in ${cwd}/components.json.`);
|
|
110
|
-
}
|
|
111
|
-
}
|
|
112
|
-
|
|
113
|
-
// src/commands/add.ts
|
|
114
|
-
var SHADCN_CLI_VERSION = "0.8.0";
|
|
115
|
-
var getTargetPath = (config, pathOverride) => {
|
|
116
|
-
const baseConfig = pathOverride ?? getComponentTargetPath(config);
|
|
117
|
-
if (!baseConfig) {
|
|
118
|
-
console.warn(
|
|
119
|
-
`Unable to determine the base path. Please run ${chalk.green(
|
|
120
|
-
"npx shadcn-ui init"
|
|
121
|
-
)} to create a components.json file.`
|
|
122
|
-
);
|
|
123
|
-
process.exit(1);
|
|
124
|
-
}
|
|
125
|
-
return [baseConfig, path3.join(baseConfig, "assistant-ui")];
|
|
126
|
-
};
|
|
127
|
-
var add = new Command().name("add").description("add a component to your project").argument("[components...]", "the components to add").option("-y, --yes", "skip confirmation prompt.", true).option("-o, --overwrite", "overwrite existing files.", false).option(
|
|
128
|
-
"-c, --cwd <cwd>",
|
|
129
|
-
"the working directory. defaults to the current directory.",
|
|
130
|
-
process.cwd()
|
|
131
|
-
).option("-a, --all", "add all available components", false).option("-p, --path <path>", "the path to add the component to.").action(async (_, opts) => {
|
|
132
|
-
const cwd = path3.resolve(opts.cwd);
|
|
133
|
-
const config = await getConfig(cwd);
|
|
134
|
-
if (!config) {
|
|
135
|
-
console.warn(
|
|
136
|
-
`Configuration is missing. Please run ${chalk.green(
|
|
137
|
-
"npx shadcn-ui init"
|
|
138
|
-
)} to create a components.json file.`
|
|
139
|
-
);
|
|
140
|
-
process.exit(1);
|
|
141
|
-
}
|
|
142
|
-
const [basePath, targetPath] = getTargetPath(config, opts.path);
|
|
143
|
-
if (targetPath && !existsSync(targetPath)) {
|
|
144
|
-
mkdirSync(targetPath, { recursive: true });
|
|
145
|
-
}
|
|
146
|
-
const child = spawn(
|
|
147
|
-
"npx",
|
|
148
|
-
[
|
|
149
|
-
`shadcn-ui@${SHADCN_CLI_VERSION}`,
|
|
150
|
-
...process.argv.slice(2),
|
|
151
|
-
"--path",
|
|
152
|
-
basePath
|
|
153
|
-
],
|
|
154
|
-
{
|
|
155
|
-
stdio: "inherit",
|
|
156
|
-
env: {
|
|
157
|
-
COMPONENTS_REGISTRY_URL: "https://www.assistant-ui.com",
|
|
158
|
-
...process.env
|
|
159
|
-
}
|
|
160
|
-
}
|
|
161
|
-
);
|
|
162
|
-
child.on("error", (error) => {
|
|
163
|
-
console.error(`Error: ${error.message}`);
|
|
164
|
-
});
|
|
165
|
-
child.on("close", (code) => {
|
|
166
|
-
if (code !== 0) {
|
|
167
|
-
console.log(`other-package-script process exited with code ${code}`);
|
|
168
|
-
}
|
|
169
|
-
});
|
|
170
|
-
});
|
|
171
|
-
|
|
172
3
|
// src/index.ts
|
|
173
4
|
import { Command as Command3 } from "commander";
|
|
174
5
|
|
|
175
6
|
// package.json
|
|
176
7
|
var package_default = {
|
|
177
8
|
name: "assistant-ui",
|
|
178
|
-
version: "0.0.
|
|
9
|
+
version: "0.0.20",
|
|
179
10
|
license: "MIT",
|
|
180
11
|
type: "module",
|
|
181
12
|
dependencies: {
|
|
182
13
|
chalk: "^5.3.0",
|
|
183
14
|
commander: "^12.1.0",
|
|
184
|
-
|
|
185
|
-
"cross-spawn": "^7.0.3",
|
|
186
|
-
"shadcn-ui": "0.8.0",
|
|
187
|
-
"tsconfig-paths": "^4.2.0",
|
|
188
|
-
zod: "^3.23.8"
|
|
15
|
+
"cross-spawn": "^7.0.5"
|
|
189
16
|
},
|
|
190
17
|
devDependencies: {
|
|
191
18
|
"@assistant-ui/tsconfig": "workspace:*",
|
|
192
19
|
"@types/cross-spawn": "^6.0.6",
|
|
193
20
|
"@types/node": "^22.9.0",
|
|
21
|
+
"eslint-config-next": "15.0.3",
|
|
194
22
|
tsup: "8.3.5"
|
|
195
23
|
},
|
|
196
24
|
files: [
|
|
@@ -202,7 +30,8 @@ var package_default = {
|
|
|
202
30
|
build: "tsup src/index.ts --format esm --sourcemap --clean"
|
|
203
31
|
},
|
|
204
32
|
publishConfig: {
|
|
205
|
-
access: "public"
|
|
33
|
+
access: "public",
|
|
34
|
+
provenance: true
|
|
206
35
|
},
|
|
207
36
|
homepage: "https://assistant-ui.com/",
|
|
208
37
|
repository: {
|
|
@@ -215,10 +44,10 @@ var package_default = {
|
|
|
215
44
|
};
|
|
216
45
|
|
|
217
46
|
// src/commands/create.ts
|
|
218
|
-
import { Command
|
|
219
|
-
import
|
|
220
|
-
import { spawn
|
|
221
|
-
var create = new
|
|
47
|
+
import { Command } from "commander";
|
|
48
|
+
import chalk from "chalk";
|
|
49
|
+
import { spawn } from "cross-spawn";
|
|
50
|
+
var create = new Command().name("create").description("create a new project").argument("[project-directory]").usage(`${chalk.green("[project-directory]")} [options]`).option(
|
|
222
51
|
"-t, --template <template>",
|
|
223
52
|
`
|
|
224
53
|
|
|
@@ -267,7 +96,7 @@ var create = new Command2().name("create").description("create a new project").a
|
|
|
267
96
|
const filteredArgs = process.argv.slice(3).filter((arg, index, arr) => {
|
|
268
97
|
return !(arg === "-t" || arg === "--template" || arr[index - 1] === "-t" || arr[index - 1] === "--template");
|
|
269
98
|
});
|
|
270
|
-
const child =
|
|
99
|
+
const child = spawn(
|
|
271
100
|
"npx",
|
|
272
101
|
[`create-next-app@latest`, ...filteredArgs, "-e", templateUrl],
|
|
273
102
|
{
|
|
@@ -284,6 +113,36 @@ var create = new Command2().name("create").description("create a new project").a
|
|
|
284
113
|
});
|
|
285
114
|
});
|
|
286
115
|
|
|
116
|
+
// src/commands/shadcn/add.ts
|
|
117
|
+
import { Command as Command2 } from "commander";
|
|
118
|
+
import { spawn as spawn2 } from "cross-spawn";
|
|
119
|
+
var shadcnAdd = new Command2().name("add").description("add a component to your project").argument("<components...>", "the components to add").option("-y, --yes", "skip confirmation prompt.", true).option("-o, --overwrite", "overwrite existing files.", false).option(
|
|
120
|
+
"-c, --cwd <cwd>",
|
|
121
|
+
"the working directory. defaults to the current directory.",
|
|
122
|
+
process.cwd()
|
|
123
|
+
).option("-p, --path <path>", "the path to add the component to.").action(async (components, opts) => {
|
|
124
|
+
const componentsToAdd = components.map(
|
|
125
|
+
(c) => `"https://r.assistant-ui.com/shadcn/${c}"`
|
|
126
|
+
);
|
|
127
|
+
const args = [`shadcn@latest`, "add", ...componentsToAdd];
|
|
128
|
+
if (opts.yes) args.push("--yes");
|
|
129
|
+
if (opts.overwrite) args.push("--overwrite");
|
|
130
|
+
if (opts.cwd) args.push("--cwd", opts.cwd);
|
|
131
|
+
if (opts.path) args.push("--path", opts.path);
|
|
132
|
+
const child = spawn2("npx", args, {
|
|
133
|
+
stdio: "inherit",
|
|
134
|
+
shell: true
|
|
135
|
+
});
|
|
136
|
+
child.on("error", (error) => {
|
|
137
|
+
console.error(`Error: ${error.message}`);
|
|
138
|
+
});
|
|
139
|
+
child.on("close", (code) => {
|
|
140
|
+
if (code !== 0) {
|
|
141
|
+
console.log(`other-package-script process exited with code ${code}`);
|
|
142
|
+
}
|
|
143
|
+
});
|
|
144
|
+
});
|
|
145
|
+
|
|
287
146
|
// src/index.ts
|
|
288
147
|
process.on("SIGINT", () => process.exit(0));
|
|
289
148
|
process.on("SIGTERM", () => process.exit(0));
|
|
@@ -293,7 +152,7 @@ async function main() {
|
|
|
293
152
|
"-v, --version",
|
|
294
153
|
"display the version number"
|
|
295
154
|
);
|
|
296
|
-
program.addCommand(
|
|
155
|
+
program.addCommand(shadcnAdd);
|
|
297
156
|
program.addCommand(create);
|
|
298
157
|
program.parse();
|
|
299
158
|
}
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/commands/add.ts","../src/utils/get-component-target-path.ts","../src/utils/get-config.ts","../src/utils/resolve-import.ts","../src/index.ts","../package.json","../src/commands/create.ts"],"sourcesContent":["import { existsSync, mkdirSync } from \"node:fs\";\nimport path from \"node:path\";\nimport chalk from \"chalk\";\nimport { Command } from \"commander\";\nimport { spawn } from \"cross-spawn\";\nimport { getComponentTargetPath } from \"../utils/get-component-target-path\";\nimport { type Config, getConfig } from \"../utils/get-config\";\n\nconst SHADCN_CLI_VERSION = \"0.8.0\";\n\nconst getTargetPath = (config: Config, pathOverride: string) => {\n const baseConfig = pathOverride ?? getComponentTargetPath(config);\n if (!baseConfig) {\n console.warn(\n `Unable to determine the base path. Please run ${chalk.green(\n \"npx shadcn-ui init\",\n )} to create a components.json file.`,\n );\n process.exit(1);\n }\n\n return [baseConfig, path.join(baseConfig, \"assistant-ui\")] as const;\n};\n\nexport const add = new Command()\n .name(\"add\")\n .description(\"add a component to your project\")\n .argument(\"[components...]\", \"the components to add\")\n .option(\"-y, --yes\", \"skip confirmation prompt.\", true)\n .option(\"-o, --overwrite\", \"overwrite existing files.\", false)\n .option(\n \"-c, --cwd <cwd>\",\n \"the working directory. defaults to the current directory.\",\n process.cwd(),\n )\n .option(\"-a, --all\", \"add all available components\", false)\n .option(\"-p, --path <path>\", \"the path to add the component to.\")\n .action(async (_, opts) => {\n const cwd = path.resolve(opts.cwd);\n const config = await getConfig(cwd);\n\n if (!config) {\n console.warn(\n `Configuration is missing. Please run ${chalk.green(\n \"npx shadcn-ui init\",\n )} to create a components.json file.`,\n );\n process.exit(1);\n }\n\n const [basePath, targetPath] = getTargetPath(config, opts.path);\n\n // create target path directory if it doesnt exist\n if (targetPath && !existsSync(targetPath)) {\n mkdirSync(targetPath, { recursive: true });\n }\n\n const child = spawn(\n \"npx\",\n [\n `shadcn-ui@${SHADCN_CLI_VERSION}`,\n ...process.argv.slice(2),\n \"--path\",\n basePath,\n ],\n {\n stdio: \"inherit\",\n env: {\n COMPONENTS_REGISTRY_URL: \"https://www.assistant-ui.com\",\n ...process.env,\n },\n },\n );\n\n child.on(\"error\", (error) => {\n console.error(`Error: ${error.message}`);\n });\n\n child.on(\"close\", (code) => {\n if (code !== 0) {\n console.log(`other-package-script process exited with code ${code}`);\n }\n });\n });\n","import path from \"node:path\";\nimport type { Config } from \"./get-config\";\n\nexport function getComponentTargetPath(config: Config) {\n if (config.aliases.ui) {\n return config.resolvedPaths.ui;\n }\n\n const [parent, type] = [\"components\", \"ui\"];\n if (!(parent in config.resolvedPaths)) {\n return null;\n }\n\n return path.join(\n config.resolvedPaths[parent as keyof typeof config.resolvedPaths],\n type,\n );\n}\n","import path from \"node:path\";\nimport { cosmiconfig } from \"cosmiconfig\";\nimport { loadConfig } from \"tsconfig-paths\";\nimport { z } from \"zod\";\nimport { resolveImport } from \"./resolve-import\";\n\nconst explorer = cosmiconfig(\"components\", {\n searchPlaces: [\"components.json\"],\n});\n\nexport const rawConfigSchema = z.object({\n $schema: z.string().optional(),\n style: z.string(),\n rsc: z.coerce.boolean().default(false),\n tsx: z.coerce.boolean().default(true),\n tailwind: z.object({\n config: z.string(),\n css: z.string(),\n baseColor: z.string(),\n cssVariables: z.boolean().default(true),\n prefix: z.string().default(\"\").optional(),\n }),\n aliases: z.object({\n components: z.string(),\n utils: z.string(),\n ui: z.string().optional(),\n }),\n});\n\nexport type RawConfig = z.infer<typeof rawConfigSchema>;\n\nexport const configSchema = rawConfigSchema.extend({\n resolvedPaths: z.object({\n tailwindConfig: z.string(),\n tailwindCss: z.string(),\n utils: z.string(),\n components: z.string(),\n ui: z.string(),\n }),\n});\n\nexport type Config = z.infer<typeof configSchema>;\n\nexport async function getConfig(cwd: string) {\n const config = await getRawConfig(cwd);\n\n if (!config) {\n return null;\n }\n\n return resolveConfigPaths(cwd, config);\n}\n\nexport function resolveConfigPaths(cwd: string, config: RawConfig) {\n // Read tsconfig.json.\n const tsConfig = loadConfig(cwd);\n\n if (tsConfig.resultType === \"failed\") {\n throw new Error(\n `Failed to load ${config.tsx ? \"tsconfig\" : \"jsconfig\"}.json. ${\n tsConfig.message ?? \"\"\n }`.trim(),\n );\n }\n\n return configSchema.parse({\n ...config,\n resolvedPaths: {\n tailwindConfig: path.resolve(cwd, config.tailwind.config),\n tailwindCss: path.resolve(cwd, config.tailwind.css),\n utils: resolveImport(config.aliases[\"utils\"], tsConfig),\n components: resolveImport(config.aliases[\"components\"], tsConfig),\n ui: config.aliases[\"ui\"]\n ? resolveImport(config.aliases[\"ui\"], tsConfig)\n : resolveImport(config.aliases[\"components\"], tsConfig),\n },\n });\n}\n\nexport async function getRawConfig(cwd: string): Promise<RawConfig | null> {\n try {\n const configResult = await explorer.search(cwd);\n\n if (!configResult) {\n return null;\n }\n\n return rawConfigSchema.parse(configResult.config);\n } catch (error) {\n throw new Error(`Invalid configuration found in ${cwd}/components.json.`);\n }\n}\n","import {\n type ConfigLoaderSuccessResult,\n createMatchPath,\n} from \"tsconfig-paths\";\n\nexport function resolveImport(\n importPath: string,\n config: Pick<ConfigLoaderSuccessResult, \"absoluteBaseUrl\" | \"paths\">,\n) {\n return createMatchPath(config.absoluteBaseUrl, config.paths)(\n importPath,\n undefined,\n () => true,\n [\".ts\", \".tsx\"],\n );\n}\n","#!/usr/bin/env node\n\nimport { add } from \"@/src/commands/add\";\nimport { Command } from \"commander\";\n\nimport packageJson from \"../package.json\";\nimport { create } from \"./commands/create\";\n\nprocess.on(\"SIGINT\", () => process.exit(0));\nprocess.on(\"SIGTERM\", () => process.exit(0));\n\nasync function main() {\n const program = new Command()\n .name(\"assistant-ui\")\n .description(\"add components and dependencies to your project\")\n .version(\n packageJson.version || \"1.0.0\",\n \"-v, --version\",\n \"display the version number\",\n );\n\n program.addCommand(add);\n program.addCommand(create);\n\n program.parse();\n}\n\nmain();\n","{\n \"name\": \"assistant-ui\",\n \"version\": \"0.0.19\",\n \"license\": \"MIT\",\n \"type\": \"module\",\n \"dependencies\": {\n \"chalk\": \"^5.3.0\",\n \"commander\": \"^12.1.0\",\n \"cosmiconfig\": \"^9.0.0\",\n \"cross-spawn\": \"^7.0.3\",\n \"shadcn-ui\": \"0.8.0\",\n \"tsconfig-paths\": \"^4.2.0\",\n \"zod\": \"^3.23.8\"\n },\n \"devDependencies\": {\n \"@assistant-ui/tsconfig\": \"workspace:*\",\n \"@types/cross-spawn\": \"^6.0.6\",\n \"@types/node\": \"^22.9.0\",\n \"tsup\": \"8.3.5\"\n },\n \"files\": [\n \"dist\",\n \"README.md\"\n ],\n \"bin\": \"./dist/index.js\",\n \"scripts\": {\n \"build\": \"tsup src/index.ts --format esm --sourcemap --clean\"\n },\n \"publishConfig\": {\n \"access\": \"public\"\n },\n \"homepage\": \"https://assistant-ui.com/\",\n \"repository\": {\n \"type\": \"git\",\n \"url\": \"git+https://github.com/Yonom/assistant-ui.git\"\n },\n \"bugs\": {\n \"url\": \"https://github.com/Yonom/assistant-ui/issues\"\n }\n}\n","import { Command } from \"commander\";\nimport chalk from \"chalk\";\nimport { spawn } from \"cross-spawn\";\n\nexport const create = new Command()\n .name(\"create\")\n .description(\"create a new project\")\n .argument(\"[project-directory]\")\n .usage(`${chalk.green(\"[project-directory]\")} [options]`)\n .option(\n \"-t, --template <template>\",\n `\n\n The template to use for the project, e.g. default, langgraph\n`,\n )\n .option(\n \"--use-npm\",\n `\n\n Explicitly tell the CLI to bootstrap the application using npm\n`,\n )\n .option(\n \"--use-pnpm\",\n `\n\n Explicitly tell the CLI to bootstrap the application using pnpm\n`,\n )\n .option(\n \"--use-yarn\",\n `\n\n Explicitly tell the CLI to bootstrap the application using Yarn\n`,\n )\n .option(\n \"--use-bun\",\n `\n\n Explicitly tell the CLI to bootstrap the application using Bun\n`,\n )\n .option(\n \"--skip-install\",\n `\n\n Explicitly tell the CLI to skip installing packages\n`,\n )\n .action((_, opts) => {\n const templates = {\n default: \"https://github.com/Yonom/assistant-ui-starter\",\n langgraph: \"https://github.com/Yonom/assistant-ui-starter-langgraph\",\n };\n\n const templateUrl =\n templates[(opts.template as keyof typeof templates) ?? \"default\"];\n if (!templateUrl) {\n console.error(`Unknown template: ${opts.template}`);\n process.exit(1);\n }\n\n const filteredArgs = process.argv.slice(3).filter((arg, index, arr) => {\n return !(\n arg === \"-t\" ||\n arg === \"--template\" ||\n arr[index - 1] === \"-t\" ||\n arr[index - 1] === \"--template\"\n );\n });\n\n const child = spawn(\n \"npx\",\n [`create-next-app@latest`, ...filteredArgs, \"-e\", templateUrl],\n {\n stdio: \"inherit\",\n },\n );\n\n child.on(\"error\", (error) => {\n console.error(`Error: ${error.message}`);\n });\n\n child.on(\"close\", (code) => {\n if (code !== 0) {\n console.log(`other-package-script process exited with code ${code}`);\n }\n });\n });\n"],"mappings":";;;AAAA,SAAS,YAAY,iBAAiB;AACtC,OAAOA,WAAU;AACjB,OAAO,WAAW;AAClB,SAAS,eAAe;AACxB,SAAS,aAAa;;;ACJtB,OAAO,UAAU;AAGV,SAAS,uBAAuB,QAAgB;AACrD,MAAI,OAAO,QAAQ,IAAI;AACrB,WAAO,OAAO,cAAc;AAAA,EAC9B;AAEA,QAAM,CAAC,QAAQ,IAAI,IAAI,CAAC,cAAc,IAAI;AAC1C,MAAI,EAAE,UAAU,OAAO,gBAAgB;AACrC,WAAO;AAAA,EACT;AAEA,SAAO,KAAK;AAAA,IACV,OAAO,cAAc,MAA2C;AAAA,IAChE;AAAA,EACF;AACF;;;ACjBA,OAAOC,WAAU;AACjB,SAAS,mBAAmB;AAC5B,SAAS,kBAAkB;AAC3B,SAAS,SAAS;;;ACHlB;AAAA,EAEE;AAAA,OACK;AAEA,SA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A,IACT,WAAW;AAAA,EACb;AAEA,QAAM,cACJ,UAAW,KAAK,YAAuC,SAAS;AAClE,MAAI,CAAC,aAAa;AAChB,YAAQ,MAAM,qBAAqB,KAAK,QAAQ,EAAE;AAClD,YAAQ,KAAK,CAAC;AAAA,EAChB;AAEA,QAAM,eAAe,QAAQ,KAAK,MAAM,CAAC,EAAE,OAAO,CAAC,KAAK,OAAO,QAAQ;AACrE,WAAO,EACL,QAAQ,QACR,QAAQ,gBACR,IAAI,QAAQ,CAAC,MAAM,QACnB,IAAI,QAAQ,CAAC,MAAM;AAAA,EAEvB,CAAC;AAED,QAAM,QAAQC;AAAA,IACZ;AAAA,IACA,CAAC,0BAA0B,GAAG,cAAc,MAAM,WAAW;AAAA,IAC7D;AAAA,MACE,OAAO;AAAA,IACT;AAAA,EACF;AAEA,QAAM,GAAG,SAAS,CAAC,UAAU;AAC3B,YAAQ,MAAM,UAAU,MAAM,OAAO,EAAE;AAAA,EACzC,CAAC;AAED,QAAM,GAAG,SAAS,CAAC,SAAS;AAC1B,QAAI,SAAS,GAAG;AACd,cAAQ,IAAI,iDAAiD,IAAI,EAAE;AAAA,IACrE;AAAA,EACF,CAAC;AACH,CAAC;;;AFlFH,QAAQ,GAAG,UAAU,MAAM,QAAQ,KAAK,CAAC,CAAC;AAC1C,QAAQ,GAAG,WAAW,MAAM,QAAQ,KAAK,CAAC,CAAC;AAE3C,eAAe,OAAO;AACpB,QAAM,UAAU,IAAIC,SAAQ,EACzB,KAAK,cAAc,EACnB,YAAY,iDAAiD,EAC7D;AAAA,IACC,gBAAY,WAAW;AAAA,IACvB;AAAA,IACA;AAAA,EACF;AAEF,UAAQ,WAAW,GAAG;AACtB,UAAQ,WAAW,MAAM;AAEzB,UAAQ,MAAM;AAChB;AAEA,KAAK;","names":["path","path","path","path","Command","Command","chalk","spawn","Command"]}
|
|
1
|
+
{"version":3,"sources":["../src/index.ts","../package.json","../src/commands/create.ts","../src/commands/shadcn/add.ts"],"sourcesContent":["#!/usr/bin/env node\n\nimport { Command } from \"commander\";\n\nimport packageJson from \"../package.json\";\nimport { create } from \"./commands/create\";\nimport { shadcnAdd } from \"./commands/shadcn/add\";\n\nprocess.on(\"SIGINT\", () => process.exit(0));\nprocess.on(\"SIGTERM\", () => process.exit(0));\n\nasync function main() {\n const program = new Command()\n .name(\"assistant-ui\")\n .description(\"add components and dependencies to your project\")\n .version(\n packageJson.version || \"1.0.0\",\n \"-v, --version\",\n \"display the version number\",\n );\n\n program.addCommand(shadcnAdd);\n program.addCommand(create);\n\n program.parse();\n}\n\nmain();\n","{\n \"name\": \"assistant-ui\",\n \"version\": \"0.0.20\",\n \"license\": \"MIT\",\n \"type\": \"module\",\n \"dependencies\": {\n \"chalk\": \"^5.3.0\",\n \"commander\": \"^12.1.0\",\n \"cross-spawn\": \"^7.0.5\"\n },\n \"devDependencies\": {\n \"@assistant-ui/tsconfig\": \"workspace:*\",\n \"@types/cross-spawn\": \"^6.0.6\",\n \"@types/node\": \"^22.9.0\",\n \"eslint-config-next\": \"15.0.3\",\n \"tsup\": \"8.3.5\"\n },\n \"files\": [\n \"dist\",\n \"README.md\"\n ],\n \"bin\": \"./dist/index.js\",\n \"scripts\": {\n \"build\": \"tsup src/index.ts --format esm --sourcemap --clean\"\n },\n \"publishConfig\": {\n \"access\": \"public\",\n \"provenance\": true\n },\n \"homepage\": \"https://assistant-ui.com/\",\n \"repository\": {\n \"type\": \"git\",\n \"url\": \"git+https://github.com/Yonom/assistant-ui.git\"\n },\n \"bugs\": {\n \"url\": \"https://github.com/Yonom/assistant-ui/issues\"\n }\n}\n","import { Command } from \"commander\";\nimport chalk from \"chalk\";\nimport { spawn } from \"cross-spawn\";\n\nexport const create = new Command()\n .name(\"create\")\n .description(\"create a new project\")\n .argument(\"[project-directory]\")\n .usage(`${chalk.green(\"[project-directory]\")} [options]`)\n .option(\n \"-t, --template <template>\",\n `\n\n The template to use for the project, e.g. default, langgraph\n`,\n )\n .option(\n \"--use-npm\",\n `\n\n Explicitly tell the CLI to bootstrap the application using npm\n`,\n )\n .option(\n \"--use-pnpm\",\n `\n\n Explicitly tell the CLI to bootstrap the application using pnpm\n`,\n )\n .option(\n \"--use-yarn\",\n `\n\n Explicitly tell the CLI to bootstrap the application using Yarn\n`,\n )\n .option(\n \"--use-bun\",\n `\n\n Explicitly tell the CLI to bootstrap the application using Bun\n`,\n )\n .option(\n \"--skip-install\",\n `\n\n Explicitly tell the CLI to skip installing packages\n`,\n )\n .action((_, opts) => {\n const templates = {\n default: \"https://github.com/Yonom/assistant-ui-starter\",\n langgraph: \"https://github.com/Yonom/assistant-ui-starter-langgraph\",\n };\n\n const templateUrl =\n templates[(opts.template as keyof typeof templates) ?? \"default\"];\n if (!templateUrl) {\n console.error(`Unknown template: ${opts.template}`);\n process.exit(1);\n }\n\n const filteredArgs = process.argv.slice(3).filter((arg, index, arr) => {\n return !(\n arg === \"-t\" ||\n arg === \"--template\" ||\n arr[index - 1] === \"-t\" ||\n arr[index - 1] === \"--template\"\n );\n });\n\n const child = spawn(\n \"npx\",\n [`create-next-app@latest`, ...filteredArgs, \"-e\", templateUrl],\n {\n stdio: \"inherit\",\n },\n );\n\n child.on(\"error\", (error) => {\n console.error(`Error: ${error.message}`);\n });\n\n child.on(\"close\", (code) => {\n if (code !== 0) {\n console.log(`other-package-script process exited with code ${code}`);\n }\n });\n });\n","import { Command } from \"commander\";\nimport { spawn } from \"cross-spawn\";\n\nexport const shadcnAdd = new Command()\n .name(\"add\")\n .description(\"add a component to your project\")\n .argument(\"<components...>\", \"the components to add\")\n .option(\"-y, --yes\", \"skip confirmation prompt.\", true)\n .option(\"-o, --overwrite\", \"overwrite existing files.\", false)\n .option(\n \"-c, --cwd <cwd>\",\n \"the working directory. defaults to the current directory.\",\n process.cwd(),\n )\n .option(\"-p, --path <path>\", \"the path to add the component to.\")\n .action(async (components: string[], opts) => {\n const componentsToAdd = components.map(\n (c) => `\"https://r.assistant-ui.com/shadcn/${c}\"`,\n );\n\n const args = [`shadcn@latest`, \"add\", ...componentsToAdd];\n\n if (opts.yes) args.push(\"--yes\");\n if (opts.overwrite) args.push(\"--overwrite\");\n if (opts.cwd) args.push(\"--cwd\", opts.cwd);\n if (opts.path) args.push(\"--path\", opts.path);\n\n const child = spawn(\"npx\", args, {\n stdio: \"inherit\",\n shell: true,\n });\n\n child.on(\"error\", (error) => {\n console.error(`Error: ${error.message}`);\n });\n\n child.on(\"close\", (code) => {\n if (code !== 0) {\n console.log(`other-package-script process exited with code ${code}`);\n }\n });\n });\n"],"mappings":";;;AAEA,SAAS,WAAAA,gBAAe;;;ACFxB;AAAA,EACE,MAAQ;AAAA,EACR,SAAW;AAAA,EACX,SAAW;AAAA,EACX,MAAQ;AAAA,EACR,cAAgB;AAAA,IACd,OAAS;AAAA,IACT,WAAa;AAAA,IACb,eAAe;AAAA,EACjB;AAAA,EACA,iBAAmB;AAAA,IACjB,0BAA0B;AAAA,IAC1B,sBAAsB;AAAA,IACtB,eAAe;AAAA,IACf,sBAAsB;AAAA,IACtB,MAAQ;AAAA,EACV;AAAA,EACA,OAAS;AAAA,IACP;AAAA,IACA;AAAA,EACF;AAAA,EACA,KAAO;AAAA,EACP,SAAW;AAAA,IACT,OAAS;AAAA,EACX;AAAA,EACA,eAAiB;AAAA,IACf,QAAU;AAAA,IACV,YAAc;AAAA,EAChB;AAAA,EACA,UAAY;AAAA,EACZ,YAAc;AAAA,IACZ,MAAQ;AAAA,IACR,KAAO;AAAA,EACT;AAAA,EACA,MAAQ;AAAA,IACN,KAAO;AAAA,EACT;AACF;;;ACrCA,SAAS,eAAe;AACxB,OAAO,WAAW;AAClB,SAAS,aAAa;AAEf,IAAM,SAAS,IAAI,QAAQ,EAC/B,KAAK,QAAQ,EACb,YAAY,sBAAsB,EAClC,SAAS,qBAAqB,EAC9B,MAAM,GAAG,MAAM,MAAM,qBAAqB,CAAC,YAAY,EACvD;AAAA,EACC;AAAA,EACA;AAAA;AAAA;AAAA;AAIF,EACC;AAAA,EACC;AAAA,EACA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1
|
{
|
|
2
2
|
"name": "assistant-ui",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.20",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"dependencies": {
|
|
7
7
|
"chalk": "^5.3.0",
|
|
8
8
|
"commander": "^12.1.0",
|
|
9
|
-
"
|
|
10
|
-
"cross-spawn": "^7.0.3",
|
|
11
|
-
"shadcn-ui": "0.8.0",
|
|
12
|
-
"tsconfig-paths": "^4.2.0",
|
|
13
|
-
"zod": "^3.23.8"
|
|
9
|
+
"cross-spawn": "^7.0.5"
|
|
14
10
|
},
|
|
15
11
|
"devDependencies": {
|
|
16
12
|
"@types/cross-spawn": "^6.0.6",
|
|
17
13
|
"@types/node": "^22.9.0",
|
|
14
|
+
"eslint-config-next": "15.0.3",
|
|
18
15
|
"tsup": "8.3.5",
|
|
19
16
|
"@assistant-ui/tsconfig": "0.0.0"
|
|
20
17
|
},
|
|
@@ -24,7 +21,8 @@
|
|
|
24
21
|
],
|
|
25
22
|
"bin": "./dist/index.js",
|
|
26
23
|
"publishConfig": {
|
|
27
|
-
"access": "public"
|
|
24
|
+
"access": "public",
|
|
25
|
+
"provenance": true
|
|
28
26
|
},
|
|
29
27
|
"homepage": "https://assistant-ui.com/",
|
|
30
28
|
"repository": {
|