@ai-plugin-marketplace/cli 0.1.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 +48 -0
- package/dist/bin.d.ts +3 -0
- package/dist/bin.d.ts.map +1 -0
- package/dist/bin.js +10 -0
- package/dist/bin.js.map +1 -0
- package/dist/index.d.ts +8 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +8 -0
- package/dist/index.js.map +1 -0
- package/dist/run.d.ts +23 -0
- package/dist/run.d.ts.map +1 -0
- package/dist/run.js +175 -0
- package/dist/run.js.map +1 -0
- package/package.json +48 -0
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 Mike North
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.md
ADDED
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
# @ai-plugin-marketplace/cli
|
|
2
|
+
|
|
3
|
+
The `aipm` binary — a thin CLI wrapper around
|
|
4
|
+
[`@ai-plugin-marketplace/core`](../core).
|
|
5
|
+
|
|
6
|
+
## Install
|
|
7
|
+
|
|
8
|
+
```sh
|
|
9
|
+
pnpm add -D @ai-plugin-marketplace/cli
|
|
10
|
+
```
|
|
11
|
+
|
|
12
|
+
## Commands
|
|
13
|
+
|
|
14
|
+
| Command | Description |
|
|
15
|
+
| ----------------------------------- | ----------------------------------------------------- |
|
|
16
|
+
| `aipm init [dir]` | Scaffold a new plugin repo (default: cwd) |
|
|
17
|
+
| `aipm build [path]` | Build plugin artifacts (default: cwd) |
|
|
18
|
+
| `aipm validate [path]` | Run validators without modifying the filesystem |
|
|
19
|
+
| `aipm scaffold <name>` | Create a new plugin from templates |
|
|
20
|
+
| `aipm migrate [path]` | Apply schema migrations (no-op in this version) |
|
|
21
|
+
| `aipm check-support <plugin>` | Diagnose a plugin's target support envelope |
|
|
22
|
+
| `aipm add-target <plugin> <target>` | Scaffold target-specific files for an existing plugin |
|
|
23
|
+
| `aipm list-targets` | List target IDs this toolkit version knows about |
|
|
24
|
+
|
|
25
|
+
## Quick start
|
|
26
|
+
|
|
27
|
+
```sh
|
|
28
|
+
aipm init my-plugins
|
|
29
|
+
cd my-plugins
|
|
30
|
+
aipm scaffold my-plugin
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
## Upgrading
|
|
34
|
+
|
|
35
|
+
```sh
|
|
36
|
+
pnpm up @ai-plugin-marketplace/cli
|
|
37
|
+
```
|
|
38
|
+
|
|
39
|
+
For major upgrades, run `aipm migrate` after updating to apply any schema migrations.
|
|
40
|
+
|
|
41
|
+
## Links
|
|
42
|
+
|
|
43
|
+
- [Architecture spec](../../docs/specs/architecture.md) (§8.2 for CLI contract details)
|
|
44
|
+
- [Repository](https://github.com/ai-plugin-marketplace/tools)
|
|
45
|
+
|
|
46
|
+
## License
|
|
47
|
+
|
|
48
|
+
MIT
|
package/dist/bin.d.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"bin.d.ts","sourceRoot":"","sources":["../src/bin.ts"],"names":[],"mappings":""}
|
package/dist/bin.js
ADDED
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
import { run } from './run.js';
|
|
3
|
+
void run(process.argv.slice(2)).then((code) => {
|
|
4
|
+
process.exit(code);
|
|
5
|
+
}, (error) => {
|
|
6
|
+
const message = error instanceof Error ? error.message : String(error);
|
|
7
|
+
process.stderr.write(`aipm: ${message}\n`);
|
|
8
|
+
process.exit(1);
|
|
9
|
+
});
|
|
10
|
+
//# sourceMappingURL=bin.js.map
|
package/dist/bin.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"bin.js","sourceRoot":"","sources":["../src/bin.ts"],"names":[],"mappings":";AACA,OAAO,EAAE,GAAG,EAAE,MAAM,UAAU,CAAC;AAE/B,KAAK,GAAG,CAAC,OAAO,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,CAAC,IAAI,CAClC,CAAC,IAAI,EAAE,EAAE;IACP,OAAO,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;AACrB,CAAC,EACD,CAAC,KAAc,EAAE,EAAE;IACjB,MAAM,OAAO,GAAG,KAAK,YAAY,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC;IACvE,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,SAAS,OAAO,IAAI,CAAC,CAAC;IAC3C,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;AAClB,CAAC,CACF,CAAC"}
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @ai-plugin-marketplace/cli — programmatic entry.
|
|
3
|
+
*
|
|
4
|
+
* The `aipm` binary lives in `bin.ts`. This module exports `run()` so host processes can
|
|
5
|
+
* invoke the CLI dispatcher with an argv array of their choosing (useful for tests).
|
|
6
|
+
*/
|
|
7
|
+
export { run } from './run.js';
|
|
8
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAE,GAAG,EAAE,MAAM,UAAU,CAAC"}
|
package/dist/index.js
ADDED
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @ai-plugin-marketplace/cli — programmatic entry.
|
|
3
|
+
*
|
|
4
|
+
* The `aipm` binary lives in `bin.ts`. This module exports `run()` so host processes can
|
|
5
|
+
* invoke the CLI dispatcher with an argv array of their choosing (useful for tests).
|
|
6
|
+
*/
|
|
7
|
+
export { run } from './run.js';
|
|
8
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAE,GAAG,EAAE,MAAM,UAAU,CAAC"}
|
package/dist/run.d.ts
ADDED
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* CLI dispatcher.
|
|
3
|
+
*
|
|
4
|
+
* Maps `aipm <command>` to `@ai-plugin-marketplace/core` operations, formats output, and returns
|
|
5
|
+
* a process exit code. No business logic lives here (§8.2): argument parsing, human-readable
|
|
6
|
+
* formatting, and exit codes only.
|
|
7
|
+
*
|
|
8
|
+
* aipm init [dir]
|
|
9
|
+
* aipm build [path]
|
|
10
|
+
* aipm validate [path]
|
|
11
|
+
* aipm scaffold <name>
|
|
12
|
+
* aipm migrate [path]
|
|
13
|
+
* aipm check-support <plugin>
|
|
14
|
+
* aipm add-target <plugin> <target>
|
|
15
|
+
* aipm list-targets
|
|
16
|
+
*/
|
|
17
|
+
interface RunOptions {
|
|
18
|
+
stdout?: NodeJS.WritableStream;
|
|
19
|
+
stderr?: NodeJS.WritableStream;
|
|
20
|
+
}
|
|
21
|
+
export declare function run(argv: readonly string[], opts?: RunOptions): Promise<number>;
|
|
22
|
+
export {};
|
|
23
|
+
//# sourceMappingURL=run.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"run.d.ts","sourceRoot":"","sources":["../src/run.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;AAuBH,UAAU,UAAU;IAClB,MAAM,CAAC,EAAE,MAAM,CAAC,cAAc,CAAC;IAC/B,MAAM,CAAC,EAAE,MAAM,CAAC,cAAc,CAAC;CAChC;AAgED,wBAAsB,GAAG,CAAC,IAAI,EAAE,SAAS,MAAM,EAAE,EAAE,IAAI,GAAE,UAAe,GAAG,OAAO,CAAC,MAAM,CAAC,CA6GzF"}
|
package/dist/run.js
ADDED
|
@@ -0,0 +1,175 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* CLI dispatcher.
|
|
3
|
+
*
|
|
4
|
+
* Maps `aipm <command>` to `@ai-plugin-marketplace/core` operations, formats output, and returns
|
|
5
|
+
* a process exit code. No business logic lives here (§8.2): argument parsing, human-readable
|
|
6
|
+
* formatting, and exit codes only.
|
|
7
|
+
*
|
|
8
|
+
* aipm init [dir]
|
|
9
|
+
* aipm build [path]
|
|
10
|
+
* aipm validate [path]
|
|
11
|
+
* aipm scaffold <name>
|
|
12
|
+
* aipm migrate [path]
|
|
13
|
+
* aipm check-support <plugin>
|
|
14
|
+
* aipm add-target <plugin> <target>
|
|
15
|
+
* aipm list-targets
|
|
16
|
+
*/
|
|
17
|
+
import * as fs from 'node:fs';
|
|
18
|
+
import * as path from 'node:path';
|
|
19
|
+
import { fileURLToPath } from 'node:url';
|
|
20
|
+
import { addTarget, build, checkSupport, init, listTargets, migrate, scaffold, validate, } from '@ai-plugin-marketplace/core';
|
|
21
|
+
const HELP = `aipm — AI plugin marketplace toolkit
|
|
22
|
+
|
|
23
|
+
Usage:
|
|
24
|
+
aipm <command> [arguments]
|
|
25
|
+
|
|
26
|
+
Commands:
|
|
27
|
+
init [dir] Scaffold a new plugin repo (default: cwd)
|
|
28
|
+
build [path] Build plugin artifacts (default: cwd)
|
|
29
|
+
validate [path] Run validators on plugins (default: cwd)
|
|
30
|
+
scaffold <name> Create a new plugin from templates
|
|
31
|
+
migrate [path] Apply schema migrations (no-op in this version)
|
|
32
|
+
check-support <plugin> Diagnose a plugin's target support envelope
|
|
33
|
+
add-target <plugin> <target> Scaffold target-specific files for a plugin
|
|
34
|
+
list-targets List target IDs this toolkit knows about
|
|
35
|
+
|
|
36
|
+
Options:
|
|
37
|
+
--help, -h Show this help message
|
|
38
|
+
--version, -V Print toolkit version
|
|
39
|
+
`;
|
|
40
|
+
/** Read this package's version from its own package.json, resolved relative to the compiled file. */
|
|
41
|
+
function toolkitVersion() {
|
|
42
|
+
const pkgPath = path.join(path.dirname(fileURLToPath(import.meta.url)), '..', 'package.json');
|
|
43
|
+
const pkg = JSON.parse(fs.readFileSync(pkgPath, 'utf-8'));
|
|
44
|
+
return pkg.version;
|
|
45
|
+
}
|
|
46
|
+
/** Resolve a `<plugin>` CLI argument to a plugin directory: an explicit path, else `<cwd>/plugins/<arg>`. */
|
|
47
|
+
function resolvePluginDir(arg) {
|
|
48
|
+
const asPath = path.resolve(arg);
|
|
49
|
+
if (fs.existsSync(asPath) && fs.statSync(asPath).isDirectory())
|
|
50
|
+
return asPath;
|
|
51
|
+
return path.join(process.cwd(), 'plugins', arg);
|
|
52
|
+
}
|
|
53
|
+
/** Format a single finding as `[plugin] code (severity): message`, with an indented hint line. */
|
|
54
|
+
function formatFinding(f) {
|
|
55
|
+
const scope = f.plugin !== undefined ? `[${f.plugin}] ` : '';
|
|
56
|
+
const head = `${scope}${f.code} (${f.severity}): ${f.message}`;
|
|
57
|
+
return f.hint !== undefined ? `${head}\n hint: ${f.hint}` : head;
|
|
58
|
+
}
|
|
59
|
+
/** Write a validation result to the given stream; returns true iff it passed (no hard findings). */
|
|
60
|
+
function reportValidation(result, out) {
|
|
61
|
+
for (const finding of result.findings) {
|
|
62
|
+
out.write(`${formatFinding(finding)}\n`);
|
|
63
|
+
}
|
|
64
|
+
if (result.passed) {
|
|
65
|
+
out.write(result.findings.length === 0 ? 'OK — no findings.\n' : 'OK — no hard findings.\n');
|
|
66
|
+
}
|
|
67
|
+
return result.passed;
|
|
68
|
+
}
|
|
69
|
+
function reportSupport(report, out) {
|
|
70
|
+
out.write(`${report.plugin}: declared [${report.declared.join(', ')}]\n`);
|
|
71
|
+
for (const { target, missing } of report.missingArtifacts) {
|
|
72
|
+
out.write(` missing for ${target}: ${missing.join(', ')}\n`);
|
|
73
|
+
}
|
|
74
|
+
for (const { target, wouldNeed } of report.suggestions) {
|
|
75
|
+
out.write(` could add ${target} (would need: ${wouldNeed.join(', ')})\n`);
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
|
+
export async function run(argv, opts = {}) {
|
|
79
|
+
const out = opts.stdout ?? process.stdout;
|
|
80
|
+
const err = opts.stderr ?? process.stderr;
|
|
81
|
+
const [command, ...rest] = argv;
|
|
82
|
+
if (command === undefined || command === '--help' || command === '-h') {
|
|
83
|
+
out.write(HELP);
|
|
84
|
+
return 0;
|
|
85
|
+
}
|
|
86
|
+
if (command === '--version' || command === '-V') {
|
|
87
|
+
out.write(`${toolkitVersion()}\n`);
|
|
88
|
+
return 0;
|
|
89
|
+
}
|
|
90
|
+
try {
|
|
91
|
+
switch (command) {
|
|
92
|
+
case 'init': {
|
|
93
|
+
const dir = rest[0] ?? process.cwd();
|
|
94
|
+
await init(dir);
|
|
95
|
+
const created = path.resolve(dir);
|
|
96
|
+
out.write(`Created plugin repo at ${created}.\n`);
|
|
97
|
+
out.write('Next: run `pnpm install`, then `aipm scaffold <name>` to add a plugin.\n');
|
|
98
|
+
return 0;
|
|
99
|
+
}
|
|
100
|
+
case 'build': {
|
|
101
|
+
const target = rest[0] ?? process.cwd();
|
|
102
|
+
const results = await build(target);
|
|
103
|
+
const artifactCount = results.reduce((n, r) => n + r.artifacts.length, 0);
|
|
104
|
+
out.write(`Built ${String(results.length)} plugin(s), ${String(artifactCount)} artifact(s).\n`);
|
|
105
|
+
// §5.4: build runs validate before reporting success.
|
|
106
|
+
const result = await validate(target);
|
|
107
|
+
const passed = reportValidation(result, out);
|
|
108
|
+
return passed ? 0 : 1;
|
|
109
|
+
}
|
|
110
|
+
case 'validate': {
|
|
111
|
+
const target = rest[0] ?? process.cwd();
|
|
112
|
+
const result = await validate(target);
|
|
113
|
+
const passed = reportValidation(result, out);
|
|
114
|
+
return passed ? 0 : 1;
|
|
115
|
+
}
|
|
116
|
+
case 'scaffold': {
|
|
117
|
+
const name = rest[0];
|
|
118
|
+
if (name === undefined) {
|
|
119
|
+
err.write("aipm: 'scaffold' requires a <name> argument.\n");
|
|
120
|
+
return 2;
|
|
121
|
+
}
|
|
122
|
+
await scaffold(name);
|
|
123
|
+
out.write(`Created plugins/${name}.\n`);
|
|
124
|
+
return 0;
|
|
125
|
+
}
|
|
126
|
+
case 'migrate': {
|
|
127
|
+
const result = await migrate(rest[0] ?? process.cwd());
|
|
128
|
+
out.write(`${result.status}\n`);
|
|
129
|
+
return 0;
|
|
130
|
+
}
|
|
131
|
+
case 'check-support': {
|
|
132
|
+
const plugin = rest[0];
|
|
133
|
+
if (plugin === undefined) {
|
|
134
|
+
err.write("aipm: 'check-support' requires a <plugin> argument.\n");
|
|
135
|
+
return 2;
|
|
136
|
+
}
|
|
137
|
+
const report = await checkSupport(resolvePluginDir(plugin));
|
|
138
|
+
reportSupport(report, out);
|
|
139
|
+
return 0;
|
|
140
|
+
}
|
|
141
|
+
case 'add-target': {
|
|
142
|
+
const plugin = rest[0];
|
|
143
|
+
const target = rest[1];
|
|
144
|
+
if (plugin === undefined || target === undefined) {
|
|
145
|
+
err.write("aipm: 'add-target' requires <plugin> and <target> arguments.\n");
|
|
146
|
+
return 2;
|
|
147
|
+
}
|
|
148
|
+
const known = listTargets();
|
|
149
|
+
if (!known.includes(target)) {
|
|
150
|
+
err.write(`aipm: unknown target '${target}'. Known: ${known.join(', ')}.\n`);
|
|
151
|
+
return 2;
|
|
152
|
+
}
|
|
153
|
+
await addTarget(resolvePluginDir(plugin), target);
|
|
154
|
+
out.write(`Added '${target}' to ${plugin}.\n`);
|
|
155
|
+
return 0;
|
|
156
|
+
}
|
|
157
|
+
case 'list-targets': {
|
|
158
|
+
for (const id of listTargets()) {
|
|
159
|
+
out.write(`${id}\n`);
|
|
160
|
+
}
|
|
161
|
+
return 0;
|
|
162
|
+
}
|
|
163
|
+
default: {
|
|
164
|
+
err.write(`aipm: unknown command '${command}'. Run 'aipm --help'.\n`);
|
|
165
|
+
return 2;
|
|
166
|
+
}
|
|
167
|
+
}
|
|
168
|
+
}
|
|
169
|
+
catch (e) {
|
|
170
|
+
const message = e instanceof Error ? e.message : String(e);
|
|
171
|
+
err.write(`aipm: ${command} failed: ${message}\n`);
|
|
172
|
+
return 1;
|
|
173
|
+
}
|
|
174
|
+
}
|
|
175
|
+
//# sourceMappingURL=run.js.map
|
package/dist/run.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"run.js","sourceRoot":"","sources":["../src/run.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;AAEH,OAAO,KAAK,EAAE,MAAM,SAAS,CAAC;AAC9B,OAAO,KAAK,IAAI,MAAM,WAAW,CAAC;AAClC,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AAEzC,OAAO,EACL,SAAS,EACT,KAAK,EACL,YAAY,EACZ,IAAI,EACJ,WAAW,EACX,OAAO,EACP,QAAQ,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AC,CAAC,CAAC;gBACpB,KAAK,MAAM,EAAE,IAAI,WAAW,EAAE,EAAE,CAAC;oBAC/B,GAAG,CAAC,KAAK,CAAC,GAAG,EAAE,IAAI,CAAC,CAAC;gBACvB,CAAC;gBACD,OAAO,CAAC,CAAC;YACX,CAAC;YAED,OAAO,CAAC,CAAC,CAAC;gBACR,GAAG,CAAC,KAAK,CAAC,0BAA0B,OAAO,yBAAyB,CAAC,CAAC;gBACtE,OAAO,CAAC,CAAC;YACX,CAAC;QACH,CAAC;IACH,CAAC;IAAC,OAAO,CAAC,EAAE,CAAC;QACX,MAAM,OAAO,GAAG,CAAC,YAAY,KAAK,CAAC,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC;QAC3D,GAAG,CAAC,KAAK,CAAC,SAAS,OAAO,YAAY,OAAO,IAAI,CAAC,CAAC;QACnD,OAAO,CAAC,CAAC;IACX,CAAC;AACH,CAAC"}
|
package/package.json
ADDED
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@ai-plugin-marketplace/cli",
|
|
3
|
+
"version": "0.1.0",
|
|
4
|
+
"description": "Command-line interface for the AI plugin marketplace toolkit. Provides the `aipm` binary.",
|
|
5
|
+
"type": "module",
|
|
6
|
+
"author": "Mike North <michael.l.north@gmail.com>",
|
|
7
|
+
"main": "./dist/index.js",
|
|
8
|
+
"types": "./dist/index.d.ts",
|
|
9
|
+
"bin": {
|
|
10
|
+
"aipm": "./dist/bin.js"
|
|
11
|
+
},
|
|
12
|
+
"exports": {
|
|
13
|
+
".": {
|
|
14
|
+
"types": "./dist/index.d.ts",
|
|
15
|
+
"import": "./dist/index.js"
|
|
16
|
+
},
|
|
17
|
+
"./package.json": "./package.json"
|
|
18
|
+
},
|
|
19
|
+
"files": [
|
|
20
|
+
"dist",
|
|
21
|
+
"README.md",
|
|
22
|
+
"LICENSE"
|
|
23
|
+
],
|
|
24
|
+
"dependencies": {
|
|
25
|
+
"@ai-plugin-marketplace/core": "^0.1.0"
|
|
26
|
+
},
|
|
27
|
+
"publishConfig": {
|
|
28
|
+
"access": "public"
|
|
29
|
+
},
|
|
30
|
+
"repository": {
|
|
31
|
+
"type": "git",
|
|
32
|
+
"url": "git+https://github.com/ai-plugin-marketplace/tools.git",
|
|
33
|
+
"directory": "packages/cli"
|
|
34
|
+
},
|
|
35
|
+
"license": "MIT",
|
|
36
|
+
"engines": {
|
|
37
|
+
"node": ">=20.0.0"
|
|
38
|
+
},
|
|
39
|
+
"scripts": {
|
|
40
|
+
"build": "tsc --build",
|
|
41
|
+
"check": "nx run-many --targets=check:typecheck,check:lint-ts,test --projects=@ai-plugin-marketplace/cli",
|
|
42
|
+
"check:typecheck": "tsc --build",
|
|
43
|
+
"check:lint-ts": "eslint src",
|
|
44
|
+
"fix:lint-ts": "eslint src --fix",
|
|
45
|
+
"test": "vitest run",
|
|
46
|
+
"clean": "rimraf dist *.tsbuildinfo"
|
|
47
|
+
}
|
|
48
|
+
}
|