outfitter 0.2.2 → 0.2.3

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.
Files changed (135) hide show
  1. package/README.md +215 -116
  2. package/dist/actions.d.ts +2 -0
  3. package/dist/actions.js +34 -0
  4. package/dist/cli.js +3 -1
  5. package/dist/commands/add.d.ts +54 -0
  6. package/dist/commands/add.js +16 -0
  7. package/dist/commands/check.d.ts +91 -0
  8. package/dist/commands/check.js +14 -0
  9. package/dist/commands/demo.d.ts +21 -0
  10. package/dist/commands/demo.js +8 -0
  11. package/dist/commands/docs-module-loader.d.ts +2 -0
  12. package/dist/commands/docs-module-loader.js +8 -0
  13. package/dist/commands/doctor.d.ts +2 -0
  14. package/dist/commands/doctor.js +13 -0
  15. package/dist/commands/init.d.ts +7 -0
  16. package/dist/commands/init.js +31 -0
  17. package/dist/commands/migrate-kit.d.ts +2 -0
  18. package/dist/commands/migrate-kit.js +15 -0
  19. package/dist/commands/repo.d.ts +3 -0
  20. package/dist/commands/repo.js +9 -0
  21. package/dist/commands/scaffold.d.ts +4 -0
  22. package/dist/commands/scaffold.js +31 -0
  23. package/dist/commands/shared-deps.d.ts +36 -0
  24. package/dist/commands/shared-deps.js +10 -0
  25. package/dist/commands/update-planner.d.ts +58 -0
  26. package/dist/commands/update-planner.js +8 -0
  27. package/dist/commands/update-workspace.d.ts +76 -0
  28. package/dist/commands/update-workspace.js +16 -0
  29. package/dist/commands/update.d.ts +113 -0
  30. package/dist/commands/update.js +21 -0
  31. package/dist/create/index.d.ts +5 -0
  32. package/dist/create/index.js +29 -0
  33. package/dist/create/planner.d.ts +3 -0
  34. package/dist/create/planner.js +21 -0
  35. package/dist/create/presets.d.ts +3 -0
  36. package/dist/create/presets.js +12 -0
  37. package/dist/create/types.d.ts +2 -0
  38. package/dist/create/types.js +1 -0
  39. package/dist/engine/blocks.d.ts +3 -0
  40. package/dist/engine/blocks.js +12 -0
  41. package/dist/engine/collector.d.ts +2 -0
  42. package/dist/engine/collector.js +8 -0
  43. package/dist/engine/config.d.ts +3 -0
  44. package/dist/engine/config.js +12 -0
  45. package/dist/engine/executor.d.ts +3 -0
  46. package/dist/engine/executor.js +16 -0
  47. package/dist/engine/index.d.ts +8 -0
  48. package/dist/engine/index.js +59 -0
  49. package/dist/engine/names.d.ts +2 -0
  50. package/dist/engine/names.js +16 -0
  51. package/dist/engine/post-scaffold.d.ts +3 -0
  52. package/dist/engine/post-scaffold.js +8 -0
  53. package/dist/engine/render-plan.d.ts +7 -0
  54. package/dist/engine/render-plan.js +9 -0
  55. package/dist/engine/template.d.ts +3 -0
  56. package/dist/engine/template.js +17 -0
  57. package/dist/engine/types.d.ts +2 -0
  58. package/dist/engine/types.js +8 -0
  59. package/dist/engine/workspace.d.ts +3 -0
  60. package/dist/engine/workspace.js +13 -0
  61. package/dist/index.d.ts +228 -152
  62. package/dist/index.js +144 -14
  63. package/dist/manifest.d.ts +71 -0
  64. package/dist/manifest.js +16 -0
  65. package/dist/output-mode.d.ts +2 -0
  66. package/dist/output-mode.js +10 -0
  67. package/dist/shared/chunk-b0y0cwkr.js +5533 -0
  68. package/dist/shared/outfitter-193jvzg4.d.ts +5 -0
  69. package/dist/shared/outfitter-1dd0k853.js +194 -0
  70. package/dist/shared/outfitter-1h7k8xxt.js +29 -0
  71. package/dist/shared/outfitter-1qwpjt6w.js +125 -0
  72. package/dist/shared/outfitter-2ngep1h2.d.ts +5 -0
  73. package/dist/shared/outfitter-2np85etz.js +95 -0
  74. package/dist/shared/outfitter-33w361tc.d.ts +18 -0
  75. package/dist/shared/outfitter-344t1r38.js +1 -0
  76. package/dist/shared/outfitter-3weh61w7.d.ts +25 -0
  77. package/dist/shared/outfitter-4s9meh3j.js +221 -0
  78. package/dist/shared/outfitter-6a4bq054.js +322 -0
  79. package/dist/shared/outfitter-6bkqjk86.d.ts +3 -0
  80. package/dist/shared/outfitter-6gc3g5wk.js +98 -0
  81. package/dist/shared/outfitter-7cv5fg1m.js +61 -0
  82. package/dist/shared/outfitter-7ha7p61k.d.ts +6 -0
  83. package/dist/shared/outfitter-7r12fj7f.js +30 -0
  84. package/dist/shared/outfitter-8y2dfx6n.js +11 -0
  85. package/dist/shared/outfitter-9c8edfsn.js +715 -0
  86. package/dist/shared/outfitter-9x1brcmq.js +184 -0
  87. package/dist/shared/outfitter-a79xrm12.d.ts +17 -0
  88. package/dist/shared/outfitter-amc4jbs1.d.ts +50 -0
  89. package/dist/shared/outfitter-ara3djt0.js +73 -0
  90. package/dist/shared/outfitter-avhm5z6w.js +82 -0
  91. package/dist/shared/outfitter-b5nd42y4.d.ts +45 -0
  92. package/dist/shared/outfitter-dd0btgec.d.ts +40 -0
  93. package/dist/shared/outfitter-e2zz5wv7.d.ts +51 -0
  94. package/dist/shared/outfitter-ehp18x1n.js +1 -0
  95. package/dist/shared/outfitter-fnsmx3xg.js +750 -0
  96. package/dist/shared/outfitter-gdvm5c0b.d.ts +4 -0
  97. package/dist/shared/outfitter-gp4v5gkf.js +322 -0
  98. package/dist/shared/outfitter-h1mnzzd1.d.ts +14 -0
  99. package/dist/shared/outfitter-hpymx4m9.js +184 -0
  100. package/dist/shared/outfitter-hvsaxgcp.js +1 -0
  101. package/dist/shared/outfitter-j8yc7294.d.ts +22 -0
  102. package/dist/shared/outfitter-jyxwznk1.js +404 -0
  103. package/dist/shared/outfitter-k112c427.js +21 -0
  104. package/dist/shared/outfitter-k56rmt24.d.ts +30 -0
  105. package/dist/shared/outfitter-ksa1pp4t.d.ts +4 -0
  106. package/dist/shared/outfitter-mdt37hqm.js +4 -0
  107. package/dist/shared/outfitter-mtbpabf3.js +91 -0
  108. package/dist/shared/outfitter-nm4m0v6x.d.ts +131 -0
  109. package/dist/shared/outfitter-nmeecf1b.js +531 -0
  110. package/dist/shared/outfitter-npyfbdmc.d.ts +6 -0
  111. package/dist/shared/outfitter-pxt58tsq.js +582 -0
  112. package/dist/shared/outfitter-q9agarmb.js +42 -0
  113. package/dist/shared/outfitter-qfgj5xpq.js +70 -0
  114. package/dist/shared/outfitter-qfh36ddg.d.ts +66 -0
  115. package/dist/shared/outfitter-s6k8y2p4.js +269 -0
  116. package/dist/shared/outfitter-sftf1s26.js +199 -0
  117. package/dist/shared/outfitter-sg7ncy4a.d.ts +51 -0
  118. package/dist/shared/outfitter-sgtq57qr.d.ts +5 -0
  119. package/dist/shared/outfitter-txre6cdn.d.ts +60 -0
  120. package/dist/shared/outfitter-vh4xgb93.js +35 -0
  121. package/dist/shared/outfitter-ya44h1km.js +191 -0
  122. package/dist/shared/outfitter-zwyvewr1.js +36 -0
  123. package/dist/targets/index.d.ts +4 -0
  124. package/dist/targets/index.js +29 -0
  125. package/dist/targets/registry.d.ts +3 -0
  126. package/dist/targets/registry.js +28 -0
  127. package/dist/targets/types.d.ts +2 -0
  128. package/dist/targets/types.js +1 -0
  129. package/package.json +154 -37
  130. package/templates/minimal/.gitignore.template +30 -0
  131. package/templates/minimal/.lefthook.yml.template +26 -0
  132. package/templates/minimal/package.json.template +46 -0
  133. package/templates/minimal/src/index.ts.template +26 -0
  134. package/templates/minimal/tsconfig.json.template +34 -0
  135. package/dist/shared/chunk-sak1tt33.js +0 -3457
@@ -0,0 +1,2 @@
1
+ import { BunVersionCheck, CheckResult, ConfigFilesCheck, DependenciesCheck, DirectoriesCheck, DoctorOptions, DoctorResult, DoctorSummary, PackageJsonCheck, doctorCommand, printDoctorResults, runDoctor } from "../shared/outfitter-nm4m0v6x";
2
+ export { runDoctor, printDoctorResults, doctorCommand, PackageJsonCheck, DoctorSummary, DoctorResult, DoctorOptions, DirectoriesCheck, DependenciesCheck, ConfigFilesCheck, CheckResult, BunVersionCheck };
@@ -0,0 +1,13 @@
1
+ // @bun
2
+ import {
3
+ doctorCommand,
4
+ printDoctorResults,
5
+ runDoctor
6
+ } from "../shared/outfitter-sftf1s26.js";
7
+ import"../shared/outfitter-7r12fj7f.js";
8
+ import"../shared/outfitter-mdt37hqm.js";
9
+ export {
10
+ runDoctor,
11
+ printDoctorResults,
12
+ doctorCommand
13
+ };
@@ -0,0 +1,7 @@
1
+ import { InitError, InitOptions, InitPresetId, InitResult, InitStructure, initCommand, printInitResults, runInit } from "../shared/outfitter-txre6cdn";
2
+ import "../shared/outfitter-y784nh31";
3
+ import "../shared/outfitter-33w361tc";
4
+ import "../shared/outfitter-k56rmt24";
5
+ import "../shared/outfitter-3weh61w7";
6
+ import "../shared/outfitter-amc4jbs1";
7
+ export { runInit, printInitResults, initCommand, InitStructure, InitResult, InitPresetId, InitOptions, InitError };
@@ -0,0 +1,31 @@
1
+ // @bun
2
+ import {
3
+ InitError,
4
+ initCommand,
5
+ printInitResults,
6
+ runInit
7
+ } from "../shared/outfitter-pxt58tsq.js";
8
+ import"../shared/outfitter-ehp18x1n.js";
9
+ import"../shared/outfitter-1dd0k853.js";
10
+ import"../shared/outfitter-4s9meh3j.js";
11
+ import"../shared/outfitter-344t1r38.js";
12
+ import"../shared/outfitter-2np85etz.js";
13
+ import"../shared/outfitter-q9agarmb.js";
14
+ import"../shared/outfitter-1qwpjt6w.js";
15
+ import"../shared/outfitter-9x1brcmq.js";
16
+ import"../shared/outfitter-7cv5fg1m.js";
17
+ import"../shared/outfitter-s6k8y2p4.js";
18
+ import"../shared/outfitter-mtbpabf3.js";
19
+ import"../shared/outfitter-6gc3g5wk.js";
20
+ import"../shared/outfitter-7r12fj7f.js";
21
+ import"../shared/outfitter-ara3djt0.js";
22
+ import"../shared/outfitter-k112c427.js";
23
+ import"../shared/outfitter-8y2dfx6n.js";
24
+ import"../shared/outfitter-1h7k8xxt.js";
25
+ import"../shared/outfitter-mdt37hqm.js";
26
+ export {
27
+ runInit,
28
+ printInitResults,
29
+ initCommand,
30
+ InitError
31
+ };
@@ -0,0 +1,2 @@
1
+ import { MigrateKitError, MigrateKitOptions, MigrateKitResult, migrateKitCommand, printMigrateKitResults, runMigrateKit } from "../shared/outfitter-sg7ncy4a";
2
+ export { runMigrateKit, printMigrateKitResults, migrateKitCommand, MigrateKitResult, MigrateKitOptions, MigrateKitError };
@@ -0,0 +1,15 @@
1
+ // @bun
2
+ import {
3
+ MigrateKitError,
4
+ migrateKitCommand,
5
+ printMigrateKitResults,
6
+ runMigrateKit
7
+ } from "../shared/outfitter-9c8edfsn.js";
8
+ import"../shared/outfitter-7r12fj7f.js";
9
+ import"../shared/outfitter-mdt37hqm.js";
10
+ export {
11
+ runMigrateKit,
12
+ printMigrateKitResults,
13
+ migrateKitCommand,
14
+ MigrateKitError
15
+ };
@@ -0,0 +1,3 @@
1
+ import { CreateRepoCommandOptions, RepoCheckSubject, RepoCommandIo, RepoToolingInvocation, createRepoCommand } from "../shared/outfitter-j8yc7294";
2
+ import "../shared/outfitter-dd0btgec";
3
+ export { createRepoCommand, RepoToolingInvocation, RepoCommandIo, RepoCheckSubject, CreateRepoCommandOptions };
@@ -0,0 +1,9 @@
1
+ // @bun
2
+ import {
3
+ createRepoCommand
4
+ } from "../shared/outfitter-hpymx4m9.js";
5
+ import"../shared/outfitter-zwyvewr1.js";
6
+ import"../shared/outfitter-mdt37hqm.js";
7
+ export {
8
+ createRepoCommand
9
+ };
@@ -0,0 +1,4 @@
1
+ import { ScaffoldCommandError, ScaffoldCommandResult, ScaffoldOptions, printScaffoldResults, runScaffold, scaffoldCommand } from "../shared/outfitter-b5nd42y4";
2
+ import "../shared/outfitter-3weh61w7";
3
+ import "../shared/outfitter-amc4jbs1";
4
+ export { scaffoldCommand, runScaffold, printScaffoldResults, ScaffoldOptions, ScaffoldCommandResult, ScaffoldCommandError };
@@ -0,0 +1,31 @@
1
+ // @bun
2
+ import {
3
+ ScaffoldCommandError,
4
+ printScaffoldResults,
5
+ runScaffold,
6
+ scaffoldCommand
7
+ } from "../shared/outfitter-nmeecf1b.js";
8
+ import"../shared/outfitter-ehp18x1n.js";
9
+ import"../shared/outfitter-1dd0k853.js";
10
+ import"../shared/outfitter-4s9meh3j.js";
11
+ import"../shared/outfitter-344t1r38.js";
12
+ import"../shared/outfitter-2np85etz.js";
13
+ import"../shared/outfitter-q9agarmb.js";
14
+ import"../shared/outfitter-1qwpjt6w.js";
15
+ import"../shared/outfitter-9x1brcmq.js";
16
+ import"../shared/outfitter-7cv5fg1m.js";
17
+ import"../shared/outfitter-s6k8y2p4.js";
18
+ import"../shared/outfitter-mtbpabf3.js";
19
+ import"../shared/outfitter-6gc3g5wk.js";
20
+ import"../shared/outfitter-7r12fj7f.js";
21
+ import"../shared/outfitter-ara3djt0.js";
22
+ import"../shared/outfitter-k112c427.js";
23
+ import"../shared/outfitter-8y2dfx6n.js";
24
+ import"../shared/outfitter-1h7k8xxt.js";
25
+ import"../shared/outfitter-mdt37hqm.js";
26
+ export {
27
+ scaffoldCommand,
28
+ runScaffold,
29
+ printScaffoldResults,
30
+ ScaffoldCommandError
31
+ };
@@ -0,0 +1,36 @@
1
+ /**
2
+ * Shared dependencies and scripts injected into all scaffolded projects.
3
+ *
4
+ * Edit this file to update versions across all templates. These are merged
5
+ * with template-specific values, with template values taking precedence.
6
+ *
7
+ * @packageDocumentation
8
+ */
9
+ /**
10
+ * Shared devDependencies injected into all scaffolded projects.
11
+ * Template-specific devDependencies take precedence over these defaults.
12
+ *
13
+ * Keep these in sync with the root package.json versions.
14
+ */
15
+ declare const SHARED_DEV_DEPS: {
16
+ readonly "@biomejs/biome": "^2.3.12";
17
+ readonly "@outfitter/tooling": "^0.2.1";
18
+ readonly "@types/bun": "^1.3.7";
19
+ readonly lefthook: "^2.0.16";
20
+ readonly typescript: "^5.9.3";
21
+ readonly ultracite: "^7.1.1";
22
+ };
23
+ /**
24
+ * Shared scripts injected into all scaffolded projects.
25
+ * Template-specific scripts take precedence over these defaults.
26
+ */
27
+ declare const SHARED_SCRIPTS: {
28
+ readonly check: "ultracite check";
29
+ readonly "clean:artifacts": "rm -rf dist .turbo";
30
+ readonly "verify:ci": "bun run typecheck && bun run check && bun run build && bun run test";
31
+ readonly lint: "biome check .";
32
+ readonly "lint:fix": "biome check . --write";
33
+ readonly format: "biome format --write .";
34
+ readonly typecheck: "tsc --noEmit";
35
+ };
36
+ export { SHARED_SCRIPTS, SHARED_DEV_DEPS };
@@ -0,0 +1,10 @@
1
+ // @bun
2
+ import {
3
+ SHARED_DEV_DEPS,
4
+ SHARED_SCRIPTS
5
+ } from "../shared/outfitter-k112c427.js";
6
+ import"../shared/outfitter-mdt37hqm.js";
7
+ export {
8
+ SHARED_SCRIPTS,
9
+ SHARED_DEV_DEPS
10
+ };
@@ -0,0 +1,58 @@
1
+ /**
2
+ * Pure, deterministic planner for the `outfitter update` command.
3
+ *
4
+ * Classifies each installed package into one of four bump categories
5
+ * based on the installed version, the latest available version, and
6
+ * metadata about whether the bump contains breaking changes.
7
+ *
8
+ * Pre-1.0 packages (major version 0) treat minor bumps as breaking
9
+ * per semver convention.
10
+ *
11
+ * @packageDocumentation
12
+ */
13
+ /** Classification of a version bump for a single package. */
14
+ type BumpClassification = "upToDate" | "upgradableNonBreaking" | "upgradableBreaking" | "blocked";
15
+ /** Describes the planned action for a single package. */
16
+ interface PackageUpdateAction {
17
+ /** Full package name (e.g. "@outfitter/cli") */
18
+ readonly name: string;
19
+ /** Currently installed version */
20
+ readonly currentVersion: string;
21
+ /** Latest available version */
22
+ readonly latestVersion: string;
23
+ /** Bump classification */
24
+ readonly classification: BumpClassification;
25
+ /** Whether this update contains breaking changes */
26
+ readonly breaking: boolean;
27
+ /** Migration doc path if available */
28
+ readonly migrationDoc?: string;
29
+ }
30
+ /** The complete update plan with per-package actions and aggregate summary. */
31
+ interface UpdatePlan {
32
+ /** Per-package update actions, sorted by name for deterministic output. */
33
+ readonly packages: PackageUpdateAction[];
34
+ /** Aggregate counts by classification. */
35
+ readonly summary: {
36
+ readonly upToDate: number;
37
+ readonly upgradableNonBreaking: number;
38
+ readonly upgradableBreaking: number;
39
+ readonly blocked: number;
40
+ };
41
+ }
42
+ /**
43
+ * Analyze installed packages against their latest versions and produce
44
+ * a deterministic update plan.
45
+ *
46
+ * This function is **pure** — no side effects, no I/O, no process.env reads.
47
+ * Same inputs always produce the same output.
48
+ *
49
+ * @param installed - Map of package name to currently installed version.
50
+ * @param latest - Map of package name to latest version info (version string + breaking flag).
51
+ * @param migrationDocs - Optional map of package name to migration doc path.
52
+ * @returns A deterministic update plan with per-package actions and summary.
53
+ */
54
+ declare function analyzeUpdates(installed: Map<string, string>, latest: Map<string, {
55
+ version: string;
56
+ breaking?: boolean;
57
+ }>, migrationDocs?: Map<string, string>): UpdatePlan;
58
+ export { analyzeUpdates, UpdatePlan, PackageUpdateAction, BumpClassification };
@@ -0,0 +1,8 @@
1
+ // @bun
2
+ import {
3
+ analyzeUpdates
4
+ } from "../shared/outfitter-qfgj5xpq.js";
5
+ import"../shared/outfitter-mdt37hqm.js";
6
+ export {
7
+ analyzeUpdates
8
+ };
@@ -0,0 +1,76 @@
1
+ import { OutfitterError } from "@outfitter/contracts";
2
+ import { Result } from "@outfitter/contracts";
3
+ /** A package dependency found across workspace manifests. */
4
+ interface WorkspacePackageEntry {
5
+ /** Full package name (e.g. "@outfitter/cli") */
6
+ readonly name: string;
7
+ /** Cleaned semver version (without range prefix) */
8
+ readonly version: string;
9
+ }
10
+ /** Version conflict: same package at different versions in different manifests. */
11
+ interface VersionConflict {
12
+ /** Full package name */
13
+ readonly name: string;
14
+ /** All distinct versions found, with their manifest paths */
15
+ readonly versions: ReadonlyArray<{
16
+ readonly version: string;
17
+ readonly manifests: readonly string[];
18
+ }>;
19
+ }
20
+ /** Result of scanning a workspace for @outfitter/* packages. */
21
+ interface WorkspaceScanResult {
22
+ /** Deduplicated @outfitter/* packages (uses lowest version for conflicts) */
23
+ readonly packages: readonly WorkspacePackageEntry[];
24
+ /** Version conflicts found across manifests */
25
+ readonly conflicts: readonly VersionConflict[];
26
+ /** Maps package name to the manifest paths that contain it */
27
+ readonly manifestsByPackage: ReadonlyMap<string, readonly string[]>;
28
+ /** All manifest paths scanned */
29
+ readonly manifestPaths: readonly string[];
30
+ /** Workspace root directory (null if not a workspace) */
31
+ readonly workspaceRoot: string | null;
32
+ }
33
+ /**
34
+ * Walk up from `cwd` looking for a workspace root.
35
+ *
36
+ * Workspace root is identified by:
37
+ * - `package.json` with a `workspaces` field (npm/yarn/bun)
38
+ * - `pnpm-workspace.yaml` file
39
+ *
40
+ * Returns `null` (as Ok) if no workspace root found — this is not an error,
41
+ * it means the project is a standalone package.
42
+ */
43
+ declare function detectWorkspaceRoot(cwd: string): Result<string | null, OutfitterError>;
44
+ /**
45
+ * Collect all package.json files from a workspace root directory.
46
+ *
47
+ * Reads workspace patterns from the root package.json, resolves globs,
48
+ * and returns sorted absolute paths to all matching package.json files.
49
+ * Always includes the root package.json itself.
50
+ */
51
+ declare function collectWorkspaceManifests(rootDir: string): Result<string[], OutfitterError>;
52
+ /**
53
+ * Scan all workspace manifests, collect @outfitter/* deps,
54
+ * deduplicate, and detect version conflicts.
55
+ *
56
+ * For deduplication: when the same package appears at the same version
57
+ * in multiple manifests, it appears once in the result.
58
+ * When versions differ, the lowest version is used and a conflict is reported.
59
+ */
60
+ declare function getInstalledPackagesFromWorkspace(rootDir: string): Result<WorkspaceScanResult, OutfitterError>;
61
+ /**
62
+ * Apply version updates to all manifests in a workspace that contain
63
+ * the specified @outfitter/* packages.
64
+ *
65
+ * Preserves the existing version range prefix (^, ~, >=, etc.) in each manifest.
66
+ * Does NOT run `bun install` — the caller is responsible for that.
67
+ */
68
+ declare function applyUpdatesToWorkspace(manifestPaths: readonly string[], manifestsByPackage: ReadonlyMap<string, readonly string[]>, updates: readonly {
69
+ name: string;
70
+ latestVersion: string;
71
+ }[]): Promise<Result<void, OutfitterError>>;
72
+ /**
73
+ * Run `bun install` at the given directory.
74
+ */
75
+ declare function runInstall(cwd: string): Promise<Result<void, OutfitterError>>;
76
+ export { runInstall, getInstalledPackagesFromWorkspace, detectWorkspaceRoot, collectWorkspaceManifests, applyUpdatesToWorkspace, WorkspaceScanResult, WorkspacePackageEntry, VersionConflict };
@@ -0,0 +1,16 @@
1
+ // @bun
2
+ import {
3
+ applyUpdatesToWorkspace,
4
+ collectWorkspaceManifests,
5
+ detectWorkspaceRoot,
6
+ getInstalledPackagesFromWorkspace,
7
+ runInstall
8
+ } from "../shared/outfitter-6a4bq054.js";
9
+ import"../shared/outfitter-mdt37hqm.js";
10
+ export {
11
+ runInstall,
12
+ getInstalledPackagesFromWorkspace,
13
+ detectWorkspaceRoot,
14
+ collectWorkspaceManifests,
15
+ applyUpdatesToWorkspace
16
+ };
@@ -0,0 +1,113 @@
1
+ import { OutputMode } from "@outfitter/cli/types";
2
+ import { OutfitterError } from "@outfitter/contracts";
3
+ import { Result } from "@outfitter/contracts";
4
+ interface UpdateOptions {
5
+ /** Working directory (defaults to cwd) */
6
+ readonly cwd: string;
7
+ /** Show migration guide */
8
+ readonly guide?: boolean;
9
+ /** Filter migration guides to specific package names */
10
+ readonly guidePackages?: readonly string[];
11
+ /** Apply non-breaking updates to package.json and run bun install */
12
+ readonly apply?: boolean;
13
+ /** Include breaking updates when --apply is used */
14
+ readonly breaking?: boolean;
15
+ /** Output mode */
16
+ readonly outputMode?: OutputMode;
17
+ }
18
+ interface PackageVersionInfo {
19
+ /** Full package name */
20
+ readonly name: string;
21
+ /** Currently installed version */
22
+ readonly current: string;
23
+ /** Latest available version from npm (null if query failed) */
24
+ readonly latest: string | null;
25
+ /** Whether an update is available */
26
+ readonly updateAvailable: boolean;
27
+ /** Whether the update contains breaking changes (major bump) */
28
+ readonly breaking: boolean;
29
+ }
30
+ interface MigrationGuide {
31
+ /** The @outfitter/* package name */
32
+ readonly packageName: string;
33
+ /** Currently installed version */
34
+ readonly fromVersion: string;
35
+ /** Latest available version */
36
+ readonly toVersion: string;
37
+ /** Whether this is a breaking change */
38
+ readonly breaking: boolean;
39
+ /** Migration step strings (empty if no guide exists) */
40
+ readonly steps: readonly string[];
41
+ }
42
+ interface UpdateResult {
43
+ /** Package version info */
44
+ readonly packages: PackageVersionInfo[];
45
+ /** Total packages checked */
46
+ readonly total: number;
47
+ /** Number of packages with updates available */
48
+ readonly updatesAvailable: number;
49
+ /** Whether any update is a breaking change */
50
+ readonly hasBreaking: boolean;
51
+ /** Whether mutations were made (--apply was used and changes were written) */
52
+ readonly applied: boolean;
53
+ /** Package names that were updated in package.json */
54
+ readonly appliedPackages: string[];
55
+ /** Package names skipped because they contain breaking changes */
56
+ readonly skippedBreaking: string[];
57
+ /** Structured migration guides (populated when --guide is used) */
58
+ readonly guides?: readonly MigrationGuide[];
59
+ }
60
+ /**
61
+ * Find migration docs directory, checking known locations.
62
+ *
63
+ * Searches:
64
+ * 1. Relative to the target cwd
65
+ * 2. Walking up parent directories from cwd (monorepo root detection)
66
+ * 3. Relative to the outfitter binary itself (development mode)
67
+ */
68
+ declare function findMigrationDocsDir(cwd: string, binaryDir?: string): string | null;
69
+ /**
70
+ * Read all migration docs for a package between two versions.
71
+ *
72
+ * Scans the migrations directory for docs matching the package name,
73
+ * filters to versions greater than `fromVersion` and at most `toVersion`,
74
+ * and returns their contents sorted by version ascending.
75
+ */
76
+ declare function readMigrationDocs(migrationsDir: string, shortName: string, fromVersion: string, toVersion: string): string[];
77
+ /**
78
+ * Read the `breaking` flag for an exact migration doc version, if present.
79
+ *
80
+ * Returns:
81
+ * - `true` or `false` when the frontmatter contains `breaking: ...`
82
+ * - `undefined` when the doc is missing, unreadable, or has no valid flag
83
+ */
84
+ declare function readMigrationBreakingFlag(migrationsDir: string, shortName: string, version: string): boolean | undefined;
85
+ /**
86
+ * Build structured migration guides for packages with available updates.
87
+ *
88
+ * For each package with an update, produces a `MigrationGuide` with steps
89
+ * extracted from migration docs (if a migrations directory is available).
90
+ * Packages without updates or without a resolved latest version are skipped.
91
+ *
92
+ * This function is pure — no side effects beyond reading migration doc files
93
+ * when `migrationsDir` is provided.
94
+ */
95
+ declare function buildMigrationGuides(packages: readonly PackageVersionInfo[], migrationsDir: string | null): MigrationGuide[];
96
+ /**
97
+ * Run the update command — detect installed versions and query npm for latest.
98
+ *
99
+ * When `apply` is true, writes updated version ranges to `package.json`
100
+ * for non-breaking upgrades only, then runs `bun install`.
101
+ */
102
+ declare function runUpdate(options: UpdateOptions): Promise<Result<UpdateResult, OutfitterError>>;
103
+ /**
104
+ * Format and output update results.
105
+ */
106
+ declare function printUpdateResults(result: UpdateResult, options?: {
107
+ mode?: OutputMode;
108
+ guide?: boolean;
109
+ cwd?: string;
110
+ applied?: boolean | undefined;
111
+ breaking?: boolean;
112
+ }): Promise<void>;
113
+ export { runUpdate, readMigrationDocs, readMigrationBreakingFlag, printUpdateResults, findMigrationDocsDir, buildMigrationGuides, UpdateResult, UpdateOptions, PackageVersionInfo, MigrationGuide };
@@ -0,0 +1,21 @@
1
+ // @bun
2
+ import {
3
+ buildMigrationGuides,
4
+ findMigrationDocsDir,
5
+ printUpdateResults,
6
+ readMigrationBreakingFlag,
7
+ readMigrationDocs,
8
+ runUpdate
9
+ } from "../shared/outfitter-jyxwznk1.js";
10
+ import"../shared/outfitter-qfgj5xpq.js";
11
+ import"../shared/outfitter-6a4bq054.js";
12
+ import"../shared/outfitter-7r12fj7f.js";
13
+ import"../shared/outfitter-mdt37hqm.js";
14
+ export {
15
+ runUpdate,
16
+ readMigrationDocs,
17
+ readMigrationBreakingFlag,
18
+ printUpdateResults,
19
+ findMigrationDocsDir,
20
+ buildMigrationGuides
21
+ };
@@ -0,0 +1,5 @@
1
+ import "../shared/outfitter-wvbpxqq7";
2
+ import { CREATE_PRESETS, CREATE_PRESET_IDS, getCreatePreset } from "../shared/outfitter-2ngep1h2";
3
+ import { planCreateProject } from "../shared/outfitter-ksa1pp4t";
4
+ import { CreatePlanChange, CreatePresetDefinition, CreatePresetId, CreateProjectInput, CreateProjectPlan } from "../shared/outfitter-e2zz5wv7";
5
+ export { planCreateProject, getCreatePreset, CreateProjectPlan, CreateProjectInput, CreatePresetId, CreatePresetDefinition, CreatePlanChange, CREATE_PRESET_IDS, CREATE_PRESETS };
@@ -0,0 +1,29 @@
1
+ // @bun
2
+ import"../shared/outfitter-hvsaxgcp.js";
3
+ import {
4
+ planCreateProject
5
+ } from "../shared/outfitter-avhm5z6w.js";
6
+ import {
7
+ CREATE_PRESETS,
8
+ CREATE_PRESET_IDS,
9
+ getCreatePreset
10
+ } from "../shared/outfitter-vh4xgb93.js";
11
+ import"../shared/outfitter-344t1r38.js";
12
+ import"../shared/outfitter-2np85etz.js";
13
+ import"../shared/outfitter-q9agarmb.js";
14
+ import"../shared/outfitter-1qwpjt6w.js";
15
+ import"../shared/outfitter-9x1brcmq.js";
16
+ import"../shared/outfitter-7cv5fg1m.js";
17
+ import"../shared/outfitter-s6k8y2p4.js";
18
+ import"../shared/outfitter-mtbpabf3.js";
19
+ import"../shared/outfitter-7r12fj7f.js";
20
+ import"../shared/outfitter-ara3djt0.js";
21
+ import"../shared/outfitter-k112c427.js";
22
+ import"../shared/outfitter-8y2dfx6n.js";
23
+ import"../shared/outfitter-mdt37hqm.js";
24
+ export {
25
+ planCreateProject,
26
+ getCreatePreset,
27
+ CREATE_PRESET_IDS,
28
+ CREATE_PRESETS
29
+ };
@@ -0,0 +1,3 @@
1
+ import { planCreateProject } from "../shared/outfitter-ksa1pp4t";
2
+ import "../shared/outfitter-e2zz5wv7";
3
+ export { planCreateProject };
@@ -0,0 +1,21 @@
1
+ // @bun
2
+ import {
3
+ planCreateProject
4
+ } from "../shared/outfitter-avhm5z6w.js";
5
+ import"../shared/outfitter-vh4xgb93.js";
6
+ import"../shared/outfitter-344t1r38.js";
7
+ import"../shared/outfitter-2np85etz.js";
8
+ import"../shared/outfitter-q9agarmb.js";
9
+ import"../shared/outfitter-1qwpjt6w.js";
10
+ import"../shared/outfitter-9x1brcmq.js";
11
+ import"../shared/outfitter-7cv5fg1m.js";
12
+ import"../shared/outfitter-s6k8y2p4.js";
13
+ import"../shared/outfitter-mtbpabf3.js";
14
+ import"../shared/outfitter-7r12fj7f.js";
15
+ import"../shared/outfitter-ara3djt0.js";
16
+ import"../shared/outfitter-k112c427.js";
17
+ import"../shared/outfitter-8y2dfx6n.js";
18
+ import"../shared/outfitter-mdt37hqm.js";
19
+ export {
20
+ planCreateProject
21
+ };
@@ -0,0 +1,3 @@
1
+ import { CREATE_PRESETS, CREATE_PRESET_IDS, getCreatePreset } from "../shared/outfitter-2ngep1h2";
2
+ import "../shared/outfitter-e2zz5wv7";
3
+ export { getCreatePreset, CREATE_PRESET_IDS, CREATE_PRESETS };
@@ -0,0 +1,12 @@
1
+ // @bun
2
+ import {
3
+ CREATE_PRESETS,
4
+ CREATE_PRESET_IDS,
5
+ getCreatePreset
6
+ } from "../shared/outfitter-vh4xgb93.js";
7
+ import"../shared/outfitter-mdt37hqm.js";
8
+ export {
9
+ getCreatePreset,
10
+ CREATE_PRESET_IDS,
11
+ CREATE_PRESETS
12
+ };
@@ -0,0 +1,2 @@
1
+ import { CreatePlanChange, CreatePresetDefinition, CreatePresetId, CreateProjectInput, CreateProjectPlan } from "../shared/outfitter-e2zz5wv7";
2
+ export { CreateProjectPlan, CreateProjectInput, CreatePresetId, CreatePresetDefinition, CreatePlanChange };
@@ -0,0 +1 @@
1
+ // @bun
@@ -0,0 +1,3 @@
1
+ import { addBlocks } from "../shared/outfitter-193jvzg4";
2
+ import "../shared/outfitter-qfh36ddg";
3
+ export { addBlocks };
@@ -0,0 +1,12 @@
1
+ // @bun
2
+ import {
3
+ addBlocks
4
+ } from "../shared/outfitter-7cv5fg1m.js";
5
+ import"../shared/outfitter-s6k8y2p4.js";
6
+ import"../shared/outfitter-mtbpabf3.js";
7
+ import"../shared/outfitter-7r12fj7f.js";
8
+ import"../shared/outfitter-8y2dfx6n.js";
9
+ import"../shared/outfitter-mdt37hqm.js";
10
+ export {
11
+ addBlocks
12
+ };
@@ -0,0 +1,2 @@
1
+ import { Operation, OperationCollector } from "../shared/outfitter-amc4jbs1";
2
+ export { OperationCollector, Operation };
@@ -0,0 +1,8 @@
1
+ // @bun
2
+ import {
3
+ OperationCollector
4
+ } from "../shared/outfitter-1h7k8xxt.js";
5
+ import"../shared/outfitter-mdt37hqm.js";
6
+ export {
7
+ OperationCollector
8
+ };
@@ -0,0 +1,3 @@
1
+ import { injectSharedConfig, rewriteLocalDependencies } from "../shared/outfitter-sgtq57qr";
2
+ import "../shared/outfitter-qfh36ddg";
3
+ export { rewriteLocalDependencies, injectSharedConfig };
@@ -0,0 +1,12 @@
1
+ // @bun
2
+ import {
3
+ injectSharedConfig,
4
+ rewriteLocalDependencies
5
+ } from "../shared/outfitter-ara3djt0.js";
6
+ import"../shared/outfitter-k112c427.js";
7
+ import"../shared/outfitter-8y2dfx6n.js";
8
+ import"../shared/outfitter-mdt37hqm.js";
9
+ export {
10
+ rewriteLocalDependencies,
11
+ injectSharedConfig
12
+ };
@@ -0,0 +1,3 @@
1
+ import { executePlan } from "../shared/outfitter-gdvm5c0b";
2
+ import "../shared/outfitter-qfh36ddg";
3
+ export { executePlan };
@@ -0,0 +1,16 @@
1
+ // @bun
2
+ import {
3
+ executePlan
4
+ } from "../shared/outfitter-1qwpjt6w.js";
5
+ import"../shared/outfitter-9x1brcmq.js";
6
+ import"../shared/outfitter-7cv5fg1m.js";
7
+ import"../shared/outfitter-s6k8y2p4.js";
8
+ import"../shared/outfitter-mtbpabf3.js";
9
+ import"../shared/outfitter-7r12fj7f.js";
10
+ import"../shared/outfitter-ara3djt0.js";
11
+ import"../shared/outfitter-k112c427.js";
12
+ import"../shared/outfitter-8y2dfx6n.js";
13
+ import"../shared/outfitter-mdt37hqm.js";
14
+ export {
15
+ executePlan
16
+ };