@inspecto-dev/cli 0.3.4 → 0.3.5
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/.turbo/turbo-build.log +7 -7
- package/.turbo/turbo-test.log +10036 -5601
- package/CHANGELOG.md +8 -0
- package/dist/bin.js +32 -1
- package/dist/{chunk-2MOEVONN.js → chunk-7ABJRH3F.js} +1232 -145
- package/dist/index.d.ts +62 -4
- package/dist/index.js +7 -1
- package/package.json +2 -2
- package/src/bin.ts +45 -0
- package/src/commands/dev-config.ts +109 -0
- package/src/commands/doctor.ts +162 -9
- package/src/commands/init.ts +10 -3
- package/src/commands/integration-automation.ts +2 -0
- package/src/commands/integration-host-ide.ts +18 -15
- package/src/commands/integration-install.ts +1 -1
- package/src/commands/onboard.ts +72 -21
- package/src/detect/build-tool.ts +14 -5
- package/src/detect/framework.ts +3 -0
- package/src/detect/package-manager.ts +1 -1
- package/src/index.ts +1 -0
- package/src/inject/gitignore.ts +13 -2
- package/src/instructions.ts +33 -7
- package/src/onboarding/apply.ts +137 -3
- package/src/onboarding/nextjs-guidance.ts +257 -0
- package/src/onboarding/nuxt-guidance.ts +129 -0
- package/src/onboarding/planner.ts +257 -6
- package/src/onboarding/session.ts +117 -27
- package/src/onboarding/target-resolution.ts +3 -3
- package/src/onboarding/umi-guidance.ts +139 -0
- package/src/types.ts +51 -3
- package/tests/apply.test.ts +319 -0
- package/tests/dev-config.test.ts +73 -0
- package/tests/doctor.test.ts +89 -0
- package/tests/init.test.ts +17 -0
- package/tests/instructions.test.ts +10 -6
- package/tests/integration-host-ide.test.ts +20 -0
- package/tests/integration-install.test.ts +65 -0
- package/tests/nextjs-guidance.test.ts +128 -0
- package/tests/nuxt-guidance.test.ts +67 -0
- package/tests/onboard.test.ts +416 -0
- package/tests/plan.test.ts +181 -21
- package/tests/runner-script.test.ts +120 -1
- package/tests/session-resolve.test.ts +116 -0
- package/tests/session.test.ts +120 -0
package/CHANGELOG.md
CHANGED
package/dist/bin.js
CHANGED
|
@@ -1,6 +1,9 @@
|
|
|
1
1
|
import {
|
|
2
2
|
apply,
|
|
3
3
|
detect,
|
|
4
|
+
devLink,
|
|
5
|
+
devStatus,
|
|
6
|
+
devUnlink,
|
|
4
7
|
doctor,
|
|
5
8
|
init,
|
|
6
9
|
installIntegration,
|
|
@@ -11,7 +14,7 @@ import {
|
|
|
11
14
|
printIntegrationPath,
|
|
12
15
|
reportCommandError,
|
|
13
16
|
teardown
|
|
14
|
-
} from "./chunk-
|
|
17
|
+
} from "./chunk-7ABJRH3F.js";
|
|
15
18
|
|
|
16
19
|
// src/bin.ts
|
|
17
20
|
import { cac } from "cac";
|
|
@@ -30,6 +33,34 @@ function exitWithError(error, options = {}) {
|
|
|
30
33
|
}
|
|
31
34
|
function createCli(_argv = process.argv) {
|
|
32
35
|
const cli = cac("inspecto");
|
|
36
|
+
cli.command("dev <subcommand>", "Manage project-local Inspecto development overrides").option("--cli-bin <path>", "Point this project at a local CLI dist/bin.js").option("--repo <path>", "Point this project at a local Inspecto repository root").option("--json", "Print machine-readable JSON output", { default: false }).option("--debug", "Enable debug mode to show full error traces", { default: false }).action(async (subcommand, options) => {
|
|
37
|
+
try {
|
|
38
|
+
if (subcommand === "link") {
|
|
39
|
+
if (!options.cliBin && !options.repo) {
|
|
40
|
+
throw new Error("The `dev link` subcommand requires --cli-bin <path> or --repo <path>.");
|
|
41
|
+
}
|
|
42
|
+
await devLink({
|
|
43
|
+
...options.cliBin ? { cliBin: options.cliBin } : {},
|
|
44
|
+
...options.repo ? { devRepo: options.repo } : {},
|
|
45
|
+
json: options.json ?? false
|
|
46
|
+
});
|
|
47
|
+
return;
|
|
48
|
+
}
|
|
49
|
+
if (subcommand === "status") {
|
|
50
|
+
await devStatus(options.json ?? false);
|
|
51
|
+
return;
|
|
52
|
+
}
|
|
53
|
+
if (subcommand === "unlink") {
|
|
54
|
+
await devUnlink(options.json ?? false);
|
|
55
|
+
return;
|
|
56
|
+
}
|
|
57
|
+
throw new Error(
|
|
58
|
+
"Usage:\n inspecto dev link [--cli-bin <path>] [--repo <path>]\n inspecto dev status [--json]\n inspecto dev unlink [--json]"
|
|
59
|
+
);
|
|
60
|
+
} catch (error) {
|
|
61
|
+
exitWithError(error, options);
|
|
62
|
+
}
|
|
63
|
+
});
|
|
33
64
|
cli.command("init", "Set up Inspecto in your project").option("--shared", "Share .inspecto/settings.json with your team via Git", { default: false }).option("--skip-install", "Skip npm dependency installation", { default: false }).option("--dry-run", "Preview changes without modifying files", { default: false }).option("--provider <provider>", "Set default provider (e.g. copilot, claude-code)").option("--no-extension", "Skip VS Code extension installation", { default: false }).option("--packages <names>", "(Monorepo) Comma-separated list of packages to inject").option("--force", "Force initialization even if environment is unsupported", {
|
|
34
65
|
default: false
|
|
35
66
|
}).option("--debug", "Enable debug mode to show full error traces", { default: false }).action(async (options) => {
|