@savvy-web/silk 1.3.6 → 1.3.8
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/changesets-changelog.cjs +4769 -7026
- package/changesets-changelog.d.cts +1350 -696
- package/changesets-changelog.d.ts +1350 -696
- package/changesets-markdownlint.cjs +4769 -7026
- package/changesets-markdownlint.d.cts +1350 -696
- package/changesets-markdownlint.d.ts +1350 -696
- package/package.json +4 -4
- package/packages/silk-effects/dist/dev/pkg/changesets/api/linter.cjs +12 -10
- package/packages/silk-effects/dist/dev/pkg/changesets/api/linter.js +9 -7
- package/packages/silk-effects/dist/dev/pkg/changesets/errors.cjs +45 -0
- package/packages/silk-effects/dist/dev/pkg/changesets/errors.js +44 -1
- package/packages/silk-effects/dist/dev/pkg/changesets/index.cjs +35 -27
- package/packages/silk-effects/dist/dev/pkg/changesets/index.js +20 -16
- package/packages/silk-effects/dist/dev/pkg/changesets/markdownlint/rules/dependency-table-format.cjs +3 -3
- package/packages/silk-effects/dist/dev/pkg/changesets/markdownlint/rules/dependency-table-format.js +1 -1
- package/packages/silk-effects/dist/dev/pkg/changesets/remark/presets.cjs +1 -1
- package/packages/silk-effects/dist/dev/pkg/changesets/remark/presets.js +1 -1
- package/packages/silk-effects/dist/dev/pkg/changesets/schemas/dependency-table.cjs +12 -1
- package/packages/silk-effects/dist/dev/pkg/changesets/schemas/dependency-table.js +12 -2
- package/packages/silk-effects/dist/dev/pkg/changesets/services/config-inspector.cjs +4 -4
- package/packages/silk-effects/dist/dev/pkg/changesets/services/config-inspector.js +1 -1
- package/packages/silk-effects/dist/dev/pkg/changesets/services/deps-regen.cjs +375 -0
- package/packages/silk-effects/dist/dev/pkg/changesets/services/deps-regen.js +371 -0
- package/packages/silk-effects/dist/dev/pkg/changesets/services/release-planner.cjs +105 -81
- package/packages/silk-effects/dist/dev/pkg/changesets/services/release-planner.js +105 -81
- package/packages/silk-effects/dist/dev/pkg/changesets/utils/dep-diff.cjs +81 -47
- package/packages/silk-effects/dist/dev/pkg/changesets/utils/dep-diff.js +81 -47
- package/packages/silk-effects/dist/dev/pkg/changesets/utils/git.cjs +51 -0
- package/packages/silk-effects/dist/dev/pkg/changesets/utils/git.js +51 -0
- package/packages/silk-effects/dist/dev/pkg/changesets/utils/publishability.cjs +16 -4
- package/packages/silk-effects/dist/dev/pkg/changesets/utils/publishability.js +15 -3
- package/packages/silk-effects/dist/dev/pkg/services/ChangesetConfig.cjs +2 -1
- package/packages/silk-effects/dist/dev/pkg/services/ChangesetConfig.js +1 -1
- package/packages/silk-effects/dist/dev/pkg/services/ChangesetConfigReader.cjs +2 -1
- package/packages/silk-effects/dist/dev/pkg/services/ChangesetConfigReader.js +1 -1
- package/packages/silk-effects/dist/dev/pkg/services/SilkPublishability.cjs +15 -11
- package/packages/silk-effects/dist/dev/pkg/services/SilkPublishability.js +5 -2
- package/tsconfig/node/dist/tsconfig.tsbuildinfo +1 -1
- package/packages/silk-effects/dist/dev/pkg/changesets/services/workspace-snapshot.cjs +0 -162
- package/packages/silk-effects/dist/dev/pkg/changesets/services/workspace-snapshot.js +0 -160
- package/packages/silk-effects/dist/dev/pkg/changesets/utils/worktree-snapshot.cjs +0 -144
- package/packages/silk-effects/dist/dev/pkg/changesets/utils/worktree-snapshot.js +0 -142
|
@@ -1,7 +1,5 @@
|
|
|
1
1
|
import { Context, Effect, Layer, Option, Schema } from "effect";
|
|
2
|
-
import { FileSystem } from "@effect/platform";
|
|
3
|
-
import { VoidIfEmpty } from "effect/Types";
|
|
4
|
-
import { YieldableError } from "effect/Cause";
|
|
2
|
+
import { CommandExecutor, FileSystem, Path } from "@effect/platform";
|
|
5
3
|
//#region ../../node_modules/.pnpm/@types+unist@3.0.3/node_modules/@types/unist/index.d.ts
|
|
6
4
|
// ## Interfaces
|
|
7
5
|
/**
|
|
@@ -3298,307 +3296,353 @@ type Label = Label$1;
|
|
|
3298
3296
|
type Severity = Severity$1;
|
|
3299
3297
|
type Plugin<Tree extends Node$3 = Node$3, Option extends unknown = unknown> = (config?: [level: Label | Severity | boolean, option?: Option] | Label | Option | Severity) => ((tree: Tree, file: VFile, next: TransformCallback<Tree>) => undefined) | undefined;
|
|
3300
3298
|
//#endregion
|
|
3301
|
-
//#region ../../node_modules/.pnpm
|
|
3302
|
-
/**
|
|
3303
|
-
*
|
|
3304
|
-
*
|
|
3299
|
+
//#region ../../node_modules/.pnpm/@pnpm+catalogs.types@1100.0.0/node_modules/@pnpm/catalogs.types/lib/index.d.ts
|
|
3300
|
+
/**
|
|
3301
|
+
* Catalogs parsed from the pnpm-workspace.yaml file.
|
|
3302
|
+
*
|
|
3303
|
+
* https://github.com/pnpm/rfcs/pull/1
|
|
3305
3304
|
*/
|
|
3306
|
-
|
|
3307
|
-
|
|
3308
|
-
|
|
3309
|
-
|
|
3310
|
-
|
|
3311
|
-
|
|
3312
|
-
|
|
3305
|
+
interface Catalogs {
|
|
3306
|
+
/**
|
|
3307
|
+
* The default catalog.
|
|
3308
|
+
*
|
|
3309
|
+
* The default catalog can be defined in 2 ways.
|
|
3310
|
+
*
|
|
3311
|
+
* 1. Users can specify a top-level "catalog" field or,
|
|
3312
|
+
* 2. An explicitly named "default" catalog under the "catalogs" map.
|
|
3313
|
+
*
|
|
3314
|
+
* This field contains either definition. Note that it's an error to define
|
|
3315
|
+
* the default catalog using both options. The parser will fail when reading
|
|
3316
|
+
* the workspace manifest.
|
|
3317
|
+
*/
|
|
3318
|
+
readonly default?: Catalog;
|
|
3319
|
+
/**
|
|
3320
|
+
* Named catalogs.
|
|
3321
|
+
*/
|
|
3322
|
+
readonly [catalogName: string]: Catalog | undefined;
|
|
3313
3323
|
}
|
|
3314
|
-
|
|
3315
|
-
|
|
3316
|
-
|
|
3317
|
-
|
|
3318
|
-
|
|
3319
|
-
|
|
3320
|
-
|
|
3321
|
-
*
|
|
3322
|
-
*
|
|
3323
|
-
*
|
|
3324
|
-
* -
|
|
3325
|
-
*
|
|
3326
|
-
*
|
|
3327
|
-
*
|
|
3328
|
-
*
|
|
3329
|
-
*
|
|
3330
|
-
*
|
|
3331
|
-
|
|
3332
|
-
|
|
3333
|
-
|
|
3334
|
-
|
|
3335
|
-
|
|
3336
|
-
*
|
|
3337
|
-
*
|
|
3338
|
-
*
|
|
3339
|
-
*
|
|
3340
|
-
*
|
|
3341
|
-
|
|
3342
|
-
|
|
3343
|
-
|
|
3344
|
-
|
|
3324
|
+
interface Catalog {
|
|
3325
|
+
readonly [dependencyName: string]: string | undefined;
|
|
3326
|
+
}
|
|
3327
|
+
//#endregion
|
|
3328
|
+
//#region ../../node_modules/.pnpm/workspaces-effect@2.0.0_@effect+platform@0.96.2_effect@3.21.4__effect@3.21.4/node_modules/workspaces-effect/index.d.ts
|
|
3329
|
+
//#region src/errors/CatalogAssemblyError.d.ts
|
|
3330
|
+
/**
|
|
3331
|
+
* Base constant for {@link CatalogAssemblyError}.
|
|
3332
|
+
*
|
|
3333
|
+
* @remarks
|
|
3334
|
+
* Exported for api-extractor DTS bundling — the `_base` symbol from
|
|
3335
|
+
* `Data.TaggedError` must be visible in the generated .d.ts file. Tagged
|
|
3336
|
+
* `@public` because it appears in the `extends` clause of a `@public`
|
|
3337
|
+
* subclass; consumers should construct and catch the subclass, not this
|
|
3338
|
+
* base directly.
|
|
3339
|
+
*
|
|
3340
|
+
* @public
|
|
3341
|
+
*/
|
|
3342
|
+
declare const CatalogAssemblyErrorBase: new <A extends Record<string, any> = {}>(args: import("effect/Types").VoidIfEmpty<{ readonly [P in keyof A as P extends "_tag" ? never : P]: A[P] }>) => import("effect/Cause").YieldableError & {
|
|
3343
|
+
readonly _tag: "CatalogAssemblyError";
|
|
3344
|
+
} & Readonly<A>;
|
|
3345
|
+
/**
|
|
3346
|
+
* Raised when assembling the workspace catalog set fails irrecoverably
|
|
3347
|
+
* (e.g. `pnpm-workspace.yaml` unreadable/malformed, default catalog defined twice).
|
|
3348
|
+
* Per-config-dependency hook failures do NOT raise this — they are logged and skipped.
|
|
3349
|
+
*
|
|
3350
|
+
* @public
|
|
3351
|
+
*/
|
|
3352
|
+
declare class CatalogAssemblyError extends CatalogAssemblyErrorBase<{
|
|
3353
|
+
readonly source: "manifest" | "config-dependency" | "lockfile";
|
|
3354
|
+
readonly reason: string;
|
|
3355
|
+
}> {
|
|
3356
|
+
get message(): string;
|
|
3357
|
+
} //#endregion
|
|
3358
|
+
//#region src/errors/CatalogResolutionError.d.ts
|
|
3359
|
+
/**
|
|
3360
|
+
* Base constant for {@link CatalogResolutionError}.
|
|
3361
|
+
*
|
|
3362
|
+
* @remarks
|
|
3363
|
+
* Exported for api-extractor DTS bundling — the `_base` symbol from
|
|
3364
|
+
* `Data.TaggedError` must be visible in the generated .d.ts file. Tagged
|
|
3365
|
+
* `@public` because it appears in the `extends` clause of a `@public`
|
|
3366
|
+
* subclass; consumers should construct and catch the subclass, not this
|
|
3367
|
+
* base directly.
|
|
3368
|
+
*
|
|
3369
|
+
* @public
|
|
3370
|
+
*/
|
|
3371
|
+
//#endregion
|
|
3372
|
+
//#region src/errors/GitReadError.d.ts
|
|
3373
|
+
/**
|
|
3374
|
+
* Base constant for {@link GitReadError}.
|
|
3375
|
+
*
|
|
3376
|
+
* @remarks
|
|
3377
|
+
* Exported for api-extractor DTS bundling — the `_base` symbol from
|
|
3378
|
+
* `Data.TaggedError` must be visible in the generated .d.ts file.
|
|
3379
|
+
*
|
|
3380
|
+
* @public
|
|
3381
|
+
*/
|
|
3382
|
+
declare const GitReadErrorBase: new <A extends Record<string, any> = {}>(args: import("effect/Types").VoidIfEmpty<{ readonly [P in keyof A as P extends "_tag" ? never : P]: A[P] }>) => import("effect/Cause").YieldableError & {
|
|
3383
|
+
readonly _tag: "GitReadError";
|
|
3384
|
+
} & Readonly<A>;
|
|
3385
|
+
/**
|
|
3386
|
+
* Raised when reading workspace state at a git ref fails irrecoverably
|
|
3387
|
+
* (git unavailable, unknown revision, command failure). A path that simply
|
|
3388
|
+
* does not exist at the ref is NOT an error — readers surface that as
|
|
3389
|
+
* `Option.none`.
|
|
3390
|
+
*
|
|
3391
|
+
* @public
|
|
3392
|
+
*/
|
|
3393
|
+
declare class GitReadError extends GitReadErrorBase<{
|
|
3394
|
+
/** The git command that failed, including arguments. */readonly command: string; /** Working directory in which the command was invoked. */
|
|
3395
|
+
readonly cwd: string; /** Human-readable failure reason — typically captured stderr. */
|
|
3396
|
+
readonly reason: string;
|
|
3397
|
+
}> {
|
|
3398
|
+
get message(): string;
|
|
3399
|
+
} //#endregion
|
|
3400
|
+
//#region src/errors/LockfileIntegrityError.d.ts
|
|
3401
|
+
/**
|
|
3402
|
+
* Base constant for {@link LockfileIntegrityError}.
|
|
3403
|
+
*
|
|
3404
|
+
* @remarks
|
|
3405
|
+
* Exported for api-extractor DTS bundling — the `_base` symbol from
|
|
3406
|
+
* `Data.TaggedError` must be visible in the generated .d.ts file. Tagged
|
|
3407
|
+
* `@public` because it appears in the `extends` clause of a `@public`
|
|
3408
|
+
* subclass; consumers should construct and catch the subclass, not this
|
|
3409
|
+
* base directly.
|
|
3410
|
+
*
|
|
3411
|
+
* @public
|
|
3412
|
+
*/
|
|
3413
|
+
//#endregion
|
|
3414
|
+
//#region src/errors/PackageJsonParseError.d.ts
|
|
3415
|
+
/**
|
|
3416
|
+
* Base constant for {@link PackageJsonParseError}.
|
|
3417
|
+
*
|
|
3418
|
+
* @remarks
|
|
3419
|
+
* Exported for api-extractor DTS bundling — the `_base` symbol from
|
|
3420
|
+
* `Data.TaggedError` must be visible in the generated .d.ts file. Tagged
|
|
3421
|
+
* `@public` because it appears in the `extends` clause of a `@public`
|
|
3422
|
+
* subclass; consumers should construct and catch the subclass, not this
|
|
3423
|
+
* base directly.
|
|
3424
|
+
*
|
|
3425
|
+
* @public
|
|
3426
|
+
*/
|
|
3427
|
+
declare const PackageJsonParseErrorBase: new <A extends Record<string, any> = {}>(args: import("effect/Types").VoidIfEmpty<{ readonly [P in keyof A as P extends "_tag" ? never : P]: A[P] }>) => import("effect/Cause").YieldableError & {
|
|
3428
|
+
readonly _tag: "PackageJsonParseError";
|
|
3429
|
+
} & Readonly<A>;
|
|
3430
|
+
/**
|
|
3431
|
+
* Emitted when a package.json file cannot be parsed or validated.
|
|
3432
|
+
*
|
|
3433
|
+
* @remarks
|
|
3434
|
+
* Raised by {@link WorkspaceDiscovery} when a package.json file is found but
|
|
3435
|
+
* contains invalid JSON or does not conform to {@link PackageJsonSchema}. The
|
|
3436
|
+
* `cause` field preserves the underlying parse or schema validation error.
|
|
3437
|
+
*
|
|
3438
|
+
* Fields:
|
|
3439
|
+
* - `filePath` — absolute path to the package.json that failed to parse.
|
|
3440
|
+
* - `cause` — the underlying error (JSON syntax error or Schema decode failure).
|
|
3441
|
+
*
|
|
3442
|
+
* @example Catching the error
|
|
3443
|
+
* ```typescript
|
|
3444
|
+
* import { Effect } from "effect";
|
|
3445
|
+
* import type { PackageJsonParseError } from "workspaces-effect";
|
|
3446
|
+
* import { WorkspaceDiscovery, WorkspaceDiscoveryLive } from "workspaces-effect";
|
|
3447
|
+
*
|
|
3448
|
+
* const program = Effect.gen(function* () {
|
|
3449
|
+
* const discovery = yield* WorkspaceDiscovery;
|
|
3450
|
+
* return yield* discovery.discover("/workspace/root");
|
|
3451
|
+
* }).pipe(
|
|
3452
|
+
* Effect.catchTag("PackageJsonParseError", (e) =>
|
|
3453
|
+
* Effect.logError(`Bad package.json at ${e.filePath}`).pipe(
|
|
3454
|
+
* Effect.map(() => [])
|
|
3455
|
+
* )
|
|
3456
|
+
* )
|
|
3457
|
+
* );
|
|
3458
|
+
* ```
|
|
3459
|
+
*
|
|
3460
|
+
* @public
|
|
3345
3461
|
*/
|
|
3346
3462
|
declare class PackageJsonParseError extends PackageJsonParseErrorBase<{
|
|
3347
3463
|
readonly filePath: string;
|
|
3348
3464
|
readonly cause: unknown;
|
|
3349
3465
|
}> {
|
|
3350
3466
|
get message(): string;
|
|
3351
|
-
}
|
|
3352
|
-
|
|
3353
|
-
|
|
3354
|
-
*
|
|
3355
|
-
*
|
|
3356
|
-
*
|
|
3357
|
-
*
|
|
3358
|
-
*
|
|
3359
|
-
*
|
|
3360
|
-
|
|
3361
|
-
|
|
3362
|
-
|
|
3363
|
-
|
|
3364
|
-
/**
|
|
3365
|
-
* Minimal package.json schema for workspace discovery.
|
|
3366
|
-
*
|
|
3367
|
-
* @remarks
|
|
3368
|
-
* Captures only the fields needed by workspace tooling — name, version,
|
|
3369
|
-
* private flag, workspace patterns, dependency maps, the `packageManager`
|
|
3370
|
-
* field (used by Corepack), and `publishConfig`. Unknown fields are silently
|
|
3371
|
-
* ignored during decode.
|
|
3372
|
-
*
|
|
3373
|
-
* Fields:
|
|
3374
|
-
* - `name` — the package name.
|
|
3375
|
-
* - `version` — the package version string.
|
|
3376
|
-
* - `private` — whether the package is private (not published).
|
|
3377
|
-
* - `workspaces` — workspace glob patterns (array or object form).
|
|
3378
|
-
* - `dependencies` — production dependency map.
|
|
3379
|
-
* - `devDependencies` — development dependency map.
|
|
3380
|
-
* - `peerDependencies` — peer dependency map.
|
|
3381
|
-
* - `packageManager` — Corepack package manager spec (e.g., `"pnpm@9.1.0"`).
|
|
3382
|
-
* - `publishConfig` — publishing configuration overrides.
|
|
3383
|
-
*
|
|
3384
|
-
* @example Decoding a package.json
|
|
3385
|
-
* ```typescript
|
|
3386
|
-
* import { Schema } from "effect";
|
|
3387
|
-
* import { PackageJsonSchema } from "workspaces-effect";
|
|
3388
|
-
*
|
|
3389
|
-
* const pkg = Schema.decodeUnknownSync(PackageJsonSchema)({
|
|
3390
|
-
* name: "@my-org/app",
|
|
3391
|
-
* version: "1.0.0",
|
|
3392
|
-
* workspaces: ["packages/*"],
|
|
3393
|
-
* });
|
|
3394
|
-
* ```
|
|
3395
|
-
*
|
|
3396
|
-
* @public
|
|
3467
|
+
} //#endregion
|
|
3468
|
+
//#region src/errors/PackageManagerDetectionError.d.ts
|
|
3469
|
+
/**
|
|
3470
|
+
* Base constant for {@link PackageManagerDetectionError}.
|
|
3471
|
+
*
|
|
3472
|
+
* @remarks
|
|
3473
|
+
* Exported for api-extractor DTS bundling — the `_base` symbol from
|
|
3474
|
+
* `Data.TaggedError` must be visible in the generated .d.ts file. Tagged
|
|
3475
|
+
* `@public` because it appears in the `extends` clause of a `@public`
|
|
3476
|
+
* subclass; consumers should construct and catch the subclass, not this
|
|
3477
|
+
* base directly.
|
|
3478
|
+
*
|
|
3479
|
+
* @public
|
|
3397
3480
|
*/
|
|
3398
|
-
|
|
3399
|
-
|
|
3400
|
-
|
|
3401
|
-
|
|
3402
|
-
|
|
3403
|
-
|
|
3404
|
-
|
|
3405
|
-
|
|
3406
|
-
|
|
3407
|
-
|
|
3408
|
-
|
|
3409
|
-
|
|
3410
|
-
|
|
3411
|
-
|
|
3412
|
-
|
|
3413
|
-
|
|
3414
|
-
|
|
3415
|
-
|
|
3416
|
-
|
|
3417
|
-
|
|
3418
|
-
|
|
3419
|
-
*
|
|
3420
|
-
*
|
|
3421
|
-
*
|
|
3422
|
-
*
|
|
3423
|
-
*
|
|
3424
|
-
*
|
|
3425
|
-
*
|
|
3426
|
-
*
|
|
3427
|
-
*
|
|
3428
|
-
*
|
|
3429
|
-
*
|
|
3430
|
-
*
|
|
3431
|
-
*
|
|
3432
|
-
*
|
|
3433
|
-
*
|
|
3434
|
-
*
|
|
3435
|
-
*
|
|
3436
|
-
*
|
|
3437
|
-
*
|
|
3438
|
-
*
|
|
3439
|
-
*
|
|
3440
|
-
*
|
|
3441
|
-
*
|
|
3442
|
-
*
|
|
3443
|
-
*
|
|
3444
|
-
* ```
|
|
3445
|
-
*
|
|
3446
|
-
* @public
|
|
3481
|
+
//#endregion
|
|
3482
|
+
//#region src/errors/PackageNotFoundError.d.ts
|
|
3483
|
+
/**
|
|
3484
|
+
* Base constant for {@link PackageNotFoundError}.
|
|
3485
|
+
*
|
|
3486
|
+
* @remarks
|
|
3487
|
+
* Exported for api-extractor DTS bundling — the `_base` symbol from
|
|
3488
|
+
* `Data.TaggedError` must be visible in the generated .d.ts file. Tagged
|
|
3489
|
+
* `@public` because it appears in the `extends` clause of a `@public`
|
|
3490
|
+
* subclass; consumers should construct and catch the subclass, not this
|
|
3491
|
+
* base directly.
|
|
3492
|
+
*
|
|
3493
|
+
* @public
|
|
3494
|
+
*/
|
|
3495
|
+
declare const PackageNotFoundErrorBase: new <A extends Record<string, any> = {}>(args: import("effect/Types").VoidIfEmpty<{ readonly [P in keyof A as P extends "_tag" ? never : P]: A[P] }>) => import("effect/Cause").YieldableError & {
|
|
3496
|
+
readonly _tag: "PackageNotFoundError";
|
|
3497
|
+
} & Readonly<A>;
|
|
3498
|
+
/**
|
|
3499
|
+
* Emitted when a named package is not found in the workspace.
|
|
3500
|
+
*
|
|
3501
|
+
* @remarks
|
|
3502
|
+
* Raised by {@link WorkspaceDiscovery} or {@link DependencyGraph} when a
|
|
3503
|
+
* lookup by package name yields no match. The `available` field lists all
|
|
3504
|
+
* known package names to aid debugging typos or missing packages.
|
|
3505
|
+
*
|
|
3506
|
+
* Fields:
|
|
3507
|
+
* - `name` — the package name that was requested but not found.
|
|
3508
|
+
* - `available` — all package names currently known in the workspace.
|
|
3509
|
+
*
|
|
3510
|
+
* @example Catching the error
|
|
3511
|
+
* ```typescript
|
|
3512
|
+
* import { Effect } from "effect";
|
|
3513
|
+
* import type { PackageNotFoundError } from "workspaces-effect";
|
|
3514
|
+
* import { DependencyGraph, DependencyGraphLive } from "workspaces-effect";
|
|
3515
|
+
*
|
|
3516
|
+
* const program = Effect.gen(function* () {
|
|
3517
|
+
* const graph = yield* DependencyGraph;
|
|
3518
|
+
* return yield* graph.dependenciesOf("@my-org/missing-pkg");
|
|
3519
|
+
* }).pipe(
|
|
3520
|
+
* Effect.catchTag("PackageNotFoundError", (e) =>
|
|
3521
|
+
* Effect.logWarning(`"${e.name}" not found. Available: ${e.available.join(", ")}`)
|
|
3522
|
+
* )
|
|
3523
|
+
* );
|
|
3524
|
+
* ```
|
|
3525
|
+
*
|
|
3526
|
+
* @public
|
|
3447
3527
|
*/
|
|
3448
3528
|
declare class PackageNotFoundError extends PackageNotFoundErrorBase<{
|
|
3449
3529
|
readonly name: string;
|
|
3450
3530
|
readonly available: ReadonlyArray<string>;
|
|
3451
3531
|
}> {
|
|
3452
3532
|
get message(): string;
|
|
3453
|
-
}
|
|
3454
|
-
|
|
3455
|
-
|
|
3456
|
-
*
|
|
3457
|
-
*
|
|
3458
|
-
*
|
|
3459
|
-
*
|
|
3460
|
-
*
|
|
3461
|
-
*
|
|
3462
|
-
|
|
3463
|
-
|
|
3464
|
-
|
|
3533
|
+
} //#endregion
|
|
3534
|
+
//#region src/errors/WorkspaceDiscoveryError.d.ts
|
|
3535
|
+
/**
|
|
3536
|
+
* Base constant for {@link WorkspaceDiscoveryError}.
|
|
3537
|
+
*
|
|
3538
|
+
* @remarks
|
|
3539
|
+
* Exported for api-extractor DTS bundling — the `_base` symbol from
|
|
3540
|
+
* `Data.TaggedError` must be visible in the generated .d.ts file. Tagged
|
|
3541
|
+
* `@public` because it appears in the `extends` clause of a `@public`
|
|
3542
|
+
* subclass; consumers should construct and catch the subclass, not this
|
|
3543
|
+
* base directly.
|
|
3544
|
+
*
|
|
3545
|
+
* @public
|
|
3546
|
+
*/
|
|
3547
|
+
declare const WorkspaceDiscoveryErrorBase: new <A extends Record<string, any> = {}>(args: import("effect/Types").VoidIfEmpty<{ readonly [P in keyof A as P extends "_tag" ? never : P]: A[P] }>) => import("effect/Cause").YieldableError & {
|
|
3548
|
+
readonly _tag: "WorkspaceDiscoveryError";
|
|
3465
3549
|
} & Readonly<A>;
|
|
3466
|
-
/**
|
|
3467
|
-
*
|
|
3468
|
-
*
|
|
3469
|
-
*
|
|
3470
|
-
*
|
|
3471
|
-
*
|
|
3472
|
-
*
|
|
3473
|
-
*
|
|
3474
|
-
*
|
|
3475
|
-
*
|
|
3476
|
-
*
|
|
3477
|
-
*
|
|
3478
|
-
*
|
|
3479
|
-
*
|
|
3480
|
-
*
|
|
3481
|
-
*
|
|
3482
|
-
*
|
|
3483
|
-
*
|
|
3484
|
-
*
|
|
3485
|
-
*
|
|
3486
|
-
*
|
|
3487
|
-
*
|
|
3488
|
-
*
|
|
3489
|
-
*
|
|
3490
|
-
*
|
|
3491
|
-
*
|
|
3492
|
-
*
|
|
3493
|
-
*
|
|
3494
|
-
*
|
|
3495
|
-
*
|
|
3496
|
-
|
|
3497
|
-
|
|
3498
|
-
|
|
3499
|
-
|
|
3500
|
-
|
|
3501
|
-
|
|
3502
|
-
|
|
3503
|
-
|
|
3504
|
-
|
|
3505
|
-
*
|
|
3506
|
-
*
|
|
3507
|
-
*
|
|
3508
|
-
*
|
|
3509
|
-
*
|
|
3510
|
-
*
|
|
3511
|
-
*
|
|
3512
|
-
*
|
|
3513
|
-
*
|
|
3514
|
-
*
|
|
3515
|
-
|
|
3516
|
-
|
|
3517
|
-
|
|
3518
|
-
|
|
3519
|
-
|
|
3520
|
-
*
|
|
3521
|
-
*
|
|
3522
|
-
*
|
|
3523
|
-
* @
|
|
3524
|
-
|
|
3525
|
-
|
|
3526
|
-
|
|
3527
|
-
|
|
3528
|
-
|
|
3529
|
-
|
|
3530
|
-
|
|
3531
|
-
|
|
3532
|
-
|
|
3533
|
-
|
|
3534
|
-
|
|
3535
|
-
|
|
3536
|
-
|
|
3537
|
-
|
|
3538
|
-
|
|
3539
|
-
|
|
3540
|
-
}
|
|
3541
|
-
|
|
3542
|
-
*
|
|
3543
|
-
*
|
|
3544
|
-
*
|
|
3545
|
-
*
|
|
3546
|
-
*
|
|
3547
|
-
* @
|
|
3548
|
-
|
|
3549
|
-
|
|
3550
|
-
|
|
3551
|
-
|
|
3552
|
-
|
|
3553
|
-
|
|
3554
|
-
|
|
3555
|
-
|
|
3556
|
-
|
|
3557
|
-
*
|
|
3558
|
-
*
|
|
3559
|
-
*
|
|
3560
|
-
*
|
|
3561
|
-
* import { WorkspacePackage } from "workspaces-effect";
|
|
3562
|
-
*
|
|
3563
|
-
* const program = Effect.gen(function* () {
|
|
3564
|
-
* const detector = yield* PublishabilityDetector;
|
|
3565
|
-
* const targets = yield* detector.detect(somePackage, "/path/to/root");
|
|
3566
|
-
* return targets;
|
|
3567
|
-
* });
|
|
3568
|
-
*
|
|
3569
|
-
* Effect.runPromise(
|
|
3570
|
-
* program.pipe(Effect.provide(PublishabilityDetectorLive))
|
|
3571
|
-
* );
|
|
3572
|
-
* ```
|
|
3573
|
-
*
|
|
3574
|
-
* @public
|
|
3575
|
-
*/
|
|
3576
|
-
/**
|
|
3577
|
-
* Schema for the `publishConfig` field in package.json.
|
|
3578
|
-
*
|
|
3579
|
-
* @remarks
|
|
3580
|
-
* Captures the subset of `publishConfig` properties relevant to workspace
|
|
3581
|
-
* tooling: registry selection, access control, and publish directory override.
|
|
3582
|
-
*
|
|
3583
|
-
* Fields:
|
|
3584
|
-
* - `access` — `"public"` or `"restricted"` (scoped package visibility).
|
|
3585
|
-
* - `registry` — custom registry URL for publishing.
|
|
3586
|
-
* - `directory` — subdirectory to publish instead of the package root.
|
|
3587
|
-
*
|
|
3588
|
-
* @example Decoding publishConfig
|
|
3589
|
-
* ```typescript
|
|
3590
|
-
* import { Schema } from "effect";
|
|
3591
|
-
* import { PublishConfig } from "workspaces-effect";
|
|
3592
|
-
*
|
|
3593
|
-
* const config = new PublishConfig({
|
|
3594
|
-
* access: "public",
|
|
3595
|
-
* registry: "https://registry.npmjs.org",
|
|
3596
|
-
* });
|
|
3597
|
-
* ```
|
|
3598
|
-
*
|
|
3599
|
-
* @public
|
|
3550
|
+
/**
|
|
3551
|
+
* Emitted when workspace package discovery fails.
|
|
3552
|
+
*
|
|
3553
|
+
* @remarks
|
|
3554
|
+
* Raised by {@link WorkspaceDiscovery} when glob expansion of workspace
|
|
3555
|
+
* patterns or subsequent package.json reads fail. This can occur if patterns
|
|
3556
|
+
* in pnpm-workspace.yaml or the root package.json `workspaces` field resolve
|
|
3557
|
+
* to invalid or inaccessible directories.
|
|
3558
|
+
*
|
|
3559
|
+
* Fields:
|
|
3560
|
+
* - `root` — the workspace root path where discovery was attempted.
|
|
3561
|
+
* - `reason` — human-readable explanation of what went wrong.
|
|
3562
|
+
*
|
|
3563
|
+
* @example Catching the error
|
|
3564
|
+
* ```typescript
|
|
3565
|
+
* import { Effect } from "effect";
|
|
3566
|
+
* import type { WorkspaceDiscoveryError } from "workspaces-effect";
|
|
3567
|
+
* import { WorkspaceDiscovery, WorkspaceDiscoveryLive } from "workspaces-effect";
|
|
3568
|
+
*
|
|
3569
|
+
* const program = Effect.gen(function* () {
|
|
3570
|
+
* const discovery = yield* WorkspaceDiscovery;
|
|
3571
|
+
* return yield* discovery.discover("/workspace/root");
|
|
3572
|
+
* }).pipe(
|
|
3573
|
+
* Effect.catchTag("WorkspaceDiscoveryError", (e) =>
|
|
3574
|
+
* Effect.succeed(`Discovery failed at ${e.root}: ${e.reason}`)
|
|
3575
|
+
* )
|
|
3576
|
+
* );
|
|
3577
|
+
* ```
|
|
3578
|
+
*
|
|
3579
|
+
* @public
|
|
3580
|
+
*/
|
|
3581
|
+
declare class WorkspaceDiscoveryError extends WorkspaceDiscoveryErrorBase<{
|
|
3582
|
+
readonly root: string;
|
|
3583
|
+
readonly reason: string;
|
|
3584
|
+
}> {
|
|
3585
|
+
get message(): string;
|
|
3586
|
+
} //#endregion
|
|
3587
|
+
//#region src/errors/WorkspaceRootNotFoundError.d.ts
|
|
3588
|
+
/**
|
|
3589
|
+
* Base constant for {@link WorkspaceRootNotFoundError}.
|
|
3590
|
+
*
|
|
3591
|
+
* @remarks
|
|
3592
|
+
* Exported for api-extractor DTS bundling — the `_base` symbol from
|
|
3593
|
+
* `Data.TaggedError` must be visible in the generated .d.ts file. Tagged
|
|
3594
|
+
* `@public` because it appears in the `extends` clause of a `@public`
|
|
3595
|
+
* subclass; consumers should construct and catch the subclass, not this
|
|
3596
|
+
* base directly.
|
|
3597
|
+
*
|
|
3598
|
+
* @public
|
|
3599
|
+
*/
|
|
3600
|
+
declare const WorkspaceRootNotFoundErrorBase: new <A extends Record<string, any> = {}>(args: import("effect/Types").VoidIfEmpty<{ readonly [P in keyof A as P extends "_tag" ? never : P]: A[P] }>) => import("effect/Cause").YieldableError & {
|
|
3601
|
+
readonly _tag: "WorkspaceRootNotFoundError";
|
|
3602
|
+
} & Readonly<A>;
|
|
3603
|
+
/**
|
|
3604
|
+
* Emitted when no workspace root can be found from the search path.
|
|
3605
|
+
*
|
|
3606
|
+
* @remarks
|
|
3607
|
+
* Raised by {@link WorkspaceRoot} when directory traversal from the search path
|
|
3608
|
+
* to the filesystem root finds no workspace markers (pnpm-workspace.yaml or
|
|
3609
|
+
* package.json with workspaces field).
|
|
3610
|
+
*
|
|
3611
|
+
* Fields:
|
|
3612
|
+
* - `searchPath` — the absolute path from which upward traversal started.
|
|
3613
|
+
* - `reason` — human-readable explanation of why no root was found.
|
|
3614
|
+
*
|
|
3615
|
+
* @example Catching the error
|
|
3616
|
+
* ```typescript
|
|
3617
|
+
* import { Effect } from "effect";
|
|
3618
|
+
* import type { WorkspaceRootNotFoundError } from "workspaces-effect";
|
|
3619
|
+
* import { WorkspaceRoot, WorkspaceRootLive } from "workspaces-effect";
|
|
3620
|
+
*
|
|
3621
|
+
* const program = Effect.gen(function* () {
|
|
3622
|
+
* const root = yield* WorkspaceRoot;
|
|
3623
|
+
* return yield* root.find("/some/path");
|
|
3624
|
+
* }).pipe(
|
|
3625
|
+
* Effect.catchTag("WorkspaceRootNotFoundError", (e) =>
|
|
3626
|
+
* Effect.succeed(`Fallback: ${e.searchPath}`)
|
|
3627
|
+
* )
|
|
3628
|
+
* );
|
|
3629
|
+
* ```
|
|
3630
|
+
*
|
|
3631
|
+
* @public
|
|
3632
|
+
*/
|
|
3633
|
+
declare class WorkspaceRootNotFoundError extends WorkspaceRootNotFoundErrorBase<{
|
|
3634
|
+
readonly searchPath: string;
|
|
3635
|
+
readonly reason: string;
|
|
3636
|
+
}> {
|
|
3637
|
+
get message(): string;
|
|
3638
|
+
} //#endregion
|
|
3639
|
+
//#region src/layers/catalog/resolve.d.ts
|
|
3640
|
+
/**
|
|
3641
|
+
* Minimal shape of a `package.json` manifest needed to resolve catalog and
|
|
3642
|
+
* workspace specifiers.
|
|
3643
|
+
*
|
|
3644
|
+
* @public
|
|
3600
3645
|
*/
|
|
3601
|
-
declare class PublishConfig extends PublishConfig_base {}
|
|
3602
3646
|
declare const PublishConfig_base: Schema.Class<PublishConfig, {
|
|
3603
3647
|
access: Schema.optional<Schema.Literal<["public", "restricted"]>>;
|
|
3604
3648
|
registry: Schema.optional<typeof Schema.String>;
|
|
@@ -3622,261 +3666,213 @@ declare const PublishConfig_base: Schema.Class<PublishConfig, {
|
|
|
3622
3666
|
} & {
|
|
3623
3667
|
readonly tag?: string | undefined;
|
|
3624
3668
|
}, {}, {}>;
|
|
3625
|
-
/**
|
|
3626
|
-
*
|
|
3627
|
-
*
|
|
3628
|
-
* @remarks
|
|
3629
|
-
*
|
|
3630
|
-
*
|
|
3631
|
-
*
|
|
3632
|
-
*
|
|
3633
|
-
*
|
|
3634
|
-
* - `
|
|
3635
|
-
* - `
|
|
3636
|
-
*
|
|
3637
|
-
*
|
|
3638
|
-
*
|
|
3639
|
-
*
|
|
3640
|
-
*
|
|
3641
|
-
*
|
|
3642
|
-
*
|
|
3643
|
-
*
|
|
3644
|
-
*
|
|
3645
|
-
*
|
|
3646
|
-
*
|
|
3647
|
-
*
|
|
3648
|
-
*
|
|
3649
|
-
|
|
3650
|
-
|
|
3651
|
-
|
|
3652
|
-
* @
|
|
3653
|
-
|
|
3654
|
-
|
|
3655
|
-
|
|
3669
|
+
/**
|
|
3670
|
+
* Schema for the `publishConfig` field in package.json.
|
|
3671
|
+
*
|
|
3672
|
+
* @remarks
|
|
3673
|
+
* Captures the subset of `publishConfig` properties relevant to workspace
|
|
3674
|
+
* tooling: registry selection, access control, and publish directory override.
|
|
3675
|
+
*
|
|
3676
|
+
* Fields:
|
|
3677
|
+
* - `access` — `"public"` or `"restricted"` (scoped package visibility).
|
|
3678
|
+
* - `registry` — custom registry URL for publishing.
|
|
3679
|
+
* - `directory` — subdirectory to publish instead of the package root.
|
|
3680
|
+
*
|
|
3681
|
+
* @example Decoding publishConfig
|
|
3682
|
+
* ```typescript
|
|
3683
|
+
* import { Schema } from "effect";
|
|
3684
|
+
* import { PublishConfig } from "workspaces-effect";
|
|
3685
|
+
*
|
|
3686
|
+
* const config = new PublishConfig({
|
|
3687
|
+
* access: "public",
|
|
3688
|
+
* registry: "https://registry.npmjs.org",
|
|
3689
|
+
* });
|
|
3690
|
+
* ```
|
|
3691
|
+
*
|
|
3692
|
+
* @public
|
|
3693
|
+
*/
|
|
3694
|
+
declare class PublishConfig extends PublishConfig_base {}
|
|
3695
|
+
/**
|
|
3696
|
+
* Type alias for the decoded shape of {@link PublishConfig}.
|
|
3697
|
+
*
|
|
3698
|
+
* @public
|
|
3699
|
+
*/
|
|
3700
|
+
/**
|
|
3701
|
+
* Minimal package.json schema for workspace discovery.
|
|
3702
|
+
*
|
|
3703
|
+
* @remarks
|
|
3704
|
+
* Captures only the fields needed by workspace tooling — name, version,
|
|
3705
|
+
* private flag, workspace patterns, dependency maps, the `packageManager`
|
|
3706
|
+
* field (used by Corepack), and `publishConfig`. Unknown fields are silently
|
|
3707
|
+
* ignored during decode.
|
|
3708
|
+
*
|
|
3709
|
+
* Fields:
|
|
3710
|
+
* - `name` — the package name.
|
|
3711
|
+
* - `version` — the package version string.
|
|
3712
|
+
* - `private` — whether the package is private (not published).
|
|
3713
|
+
* - `workspaces` — workspace glob patterns (array or object form).
|
|
3714
|
+
* - `dependencies` — production dependency map.
|
|
3715
|
+
* - `devDependencies` — development dependency map.
|
|
3716
|
+
* - `peerDependencies` — peer dependency map.
|
|
3717
|
+
* - `packageManager` — Corepack package manager spec (e.g., `"pnpm@9.1.0"`).
|
|
3718
|
+
* - `publishConfig` — publishing configuration overrides.
|
|
3719
|
+
*
|
|
3720
|
+
* @example Decoding a package.json
|
|
3721
|
+
* ```typescript
|
|
3722
|
+
* import { Schema } from "effect";
|
|
3723
|
+
* import { PackageJsonSchema } from "workspaces-effect";
|
|
3724
|
+
*
|
|
3725
|
+
* const pkg = Schema.decodeUnknownSync(PackageJsonSchema)({
|
|
3726
|
+
* name: "@my-org/app",
|
|
3727
|
+
* version: "1.0.0",
|
|
3728
|
+
* workspaces: ["packages/*"],
|
|
3729
|
+
* });
|
|
3730
|
+
* ```
|
|
3731
|
+
*
|
|
3732
|
+
* @public
|
|
3733
|
+
*/
|
|
3734
|
+
declare const PackageJsonSchema: Schema.Struct<{
|
|
3735
|
+
name: Schema.optional<typeof Schema.String>;
|
|
3736
|
+
version: Schema.optional<typeof Schema.String>;
|
|
3737
|
+
private: Schema.optional<typeof Schema.Boolean>;
|
|
3738
|
+
workspaces: Schema.optional<Schema.Union<[Schema.Array$<typeof Schema.String>, Schema.Struct<{
|
|
3739
|
+
packages: Schema.Array$<typeof Schema.String>;
|
|
3740
|
+
}>]>>;
|
|
3741
|
+
dependencies: Schema.optional<Schema.Record$<typeof Schema.String, typeof Schema.String>>;
|
|
3742
|
+
devDependencies: Schema.optional<Schema.Record$<typeof Schema.String, typeof Schema.String>>;
|
|
3743
|
+
peerDependencies: Schema.optional<Schema.Record$<typeof Schema.String, typeof Schema.String>>;
|
|
3744
|
+
optionalDependencies: Schema.optional<Schema.Record$<typeof Schema.String, typeof Schema.String>>;
|
|
3745
|
+
packageManager: Schema.optional<typeof Schema.String>;
|
|
3746
|
+
publishConfig: Schema.optional<typeof PublishConfig>;
|
|
3747
|
+
}>;
|
|
3748
|
+
/**
|
|
3749
|
+
* TypeScript type for the {@link PackageJsonSchema} schema.
|
|
3750
|
+
*
|
|
3751
|
+
* @public
|
|
3752
|
+
*/
|
|
3753
|
+
type PackageJsonType = Schema.Schema.Type<typeof PackageJsonSchema>;
|
|
3754
|
+
/**
|
|
3755
|
+
* Result of comparing two WorkspacePackage dependency snapshots.
|
|
3756
|
+
* @public
|
|
3757
|
+
*/
|
|
3758
|
+
interface DependencyDiff {
|
|
3759
|
+
readonly added: Record<string, string>;
|
|
3760
|
+
readonly removed: Record<string, string>;
|
|
3761
|
+
readonly changed: Record<string, {
|
|
3762
|
+
readonly from: string;
|
|
3763
|
+
readonly to: string;
|
|
3764
|
+
}>;
|
|
3765
|
+
}
|
|
3766
|
+
declare const WorkspacePackage_base: Schema.Class<WorkspacePackage, {
|
|
3656
3767
|
name: typeof Schema.NonEmptyString;
|
|
3657
|
-
|
|
3658
|
-
|
|
3659
|
-
|
|
3660
|
-
|
|
3768
|
+
version: typeof Schema.String;
|
|
3769
|
+
path: typeof Schema.NonEmptyString;
|
|
3770
|
+
packageJsonPath: typeof Schema.NonEmptyString;
|
|
3771
|
+
relativePath: typeof Schema.String;
|
|
3772
|
+
private: Schema.optionalWith<typeof Schema.Boolean, {
|
|
3773
|
+
default: () => false;
|
|
3774
|
+
}>;
|
|
3775
|
+
dependencies: Schema.optionalWith<Schema.Record$<typeof Schema.String, typeof Schema.String>, {
|
|
3776
|
+
default: () => {};
|
|
3777
|
+
}>;
|
|
3778
|
+
devDependencies: Schema.optionalWith<Schema.Record$<typeof Schema.String, typeof Schema.String>, {
|
|
3779
|
+
default: () => {};
|
|
3780
|
+
}>;
|
|
3781
|
+
peerDependencies: Schema.optionalWith<Schema.Record$<typeof Schema.String, typeof Schema.String>, {
|
|
3782
|
+
default: () => {};
|
|
3783
|
+
}>;
|
|
3784
|
+
optionalDependencies: Schema.optionalWith<Schema.Record$<typeof Schema.String, typeof Schema.String>, {
|
|
3785
|
+
default: () => {};
|
|
3786
|
+
}>;
|
|
3787
|
+
publishConfig: Schema.optional<typeof PublishConfig>;
|
|
3788
|
+
}, Schema.Struct.Encoded<{
|
|
3789
|
+
name: typeof Schema.NonEmptyString;
|
|
3790
|
+
version: typeof Schema.String;
|
|
3791
|
+
path: typeof Schema.NonEmptyString;
|
|
3792
|
+
packageJsonPath: typeof Schema.NonEmptyString;
|
|
3793
|
+
relativePath: typeof Schema.String;
|
|
3794
|
+
private: Schema.optionalWith<typeof Schema.Boolean, {
|
|
3661
3795
|
default: () => false;
|
|
3662
3796
|
}>;
|
|
3663
|
-
|
|
3664
|
-
|
|
3665
|
-
|
|
3666
|
-
|
|
3667
|
-
|
|
3668
|
-
|
|
3669
|
-
|
|
3797
|
+
dependencies: Schema.optionalWith<Schema.Record$<typeof Schema.String, typeof Schema.String>, {
|
|
3798
|
+
default: () => {};
|
|
3799
|
+
}>;
|
|
3800
|
+
devDependencies: Schema.optionalWith<Schema.Record$<typeof Schema.String, typeof Schema.String>, {
|
|
3801
|
+
default: () => {};
|
|
3802
|
+
}>;
|
|
3803
|
+
peerDependencies: Schema.optionalWith<Schema.Record$<typeof Schema.String, typeof Schema.String>, {
|
|
3804
|
+
default: () => {};
|
|
3805
|
+
}>;
|
|
3806
|
+
optionalDependencies: Schema.optionalWith<Schema.Record$<typeof Schema.String, typeof Schema.String>, {
|
|
3807
|
+
default: () => {};
|
|
3670
3808
|
}>;
|
|
3809
|
+
publishConfig: Schema.optional<typeof PublishConfig>;
|
|
3671
3810
|
}>, never, {
|
|
3672
|
-
readonly
|
|
3811
|
+
readonly publishConfig?: PublishConfig | undefined;
|
|
3673
3812
|
} & {
|
|
3674
|
-
readonly
|
|
3813
|
+
readonly dependencies?: {
|
|
3814
|
+
readonly [x: string]: string;
|
|
3815
|
+
} | undefined;
|
|
3675
3816
|
} & {
|
|
3676
|
-
readonly
|
|
3817
|
+
readonly devDependencies?: {
|
|
3818
|
+
readonly [x: string]: string;
|
|
3819
|
+
} | undefined;
|
|
3820
|
+
} & {
|
|
3821
|
+
readonly optionalDependencies?: {
|
|
3822
|
+
readonly [x: string]: string;
|
|
3823
|
+
} | undefined;
|
|
3824
|
+
} & {
|
|
3825
|
+
readonly peerDependencies?: {
|
|
3826
|
+
readonly [x: string]: string;
|
|
3827
|
+
} | undefined;
|
|
3828
|
+
} & {
|
|
3829
|
+
readonly private?: boolean | undefined;
|
|
3677
3830
|
} & {
|
|
3678
3831
|
readonly name: string;
|
|
3679
3832
|
} & {
|
|
3680
|
-
readonly
|
|
3833
|
+
readonly packageJsonPath: string;
|
|
3834
|
+
} & {
|
|
3835
|
+
readonly path: string;
|
|
3836
|
+
} & {
|
|
3837
|
+
readonly relativePath: string;
|
|
3838
|
+
} & {
|
|
3839
|
+
readonly version: string;
|
|
3681
3840
|
}, {}, {}>;
|
|
3682
|
-
/**
|
|
3683
|
-
*
|
|
3684
|
-
*
|
|
3685
|
-
*
|
|
3686
|
-
* package
|
|
3687
|
-
*
|
|
3688
|
-
*
|
|
3689
|
-
*
|
|
3690
|
-
|
|
3691
|
-
|
|
3692
|
-
*
|
|
3693
|
-
*
|
|
3694
|
-
*
|
|
3695
|
-
*
|
|
3696
|
-
*
|
|
3697
|
-
*
|
|
3698
|
-
*
|
|
3699
|
-
*
|
|
3700
|
-
*
|
|
3701
|
-
*
|
|
3702
|
-
*
|
|
3703
|
-
*
|
|
3704
|
-
*
|
|
3705
|
-
*
|
|
3706
|
-
*
|
|
3707
|
-
*
|
|
3708
|
-
* @
|
|
3709
|
-
*
|
|
3710
|
-
*
|
|
3711
|
-
*
|
|
3712
|
-
*
|
|
3713
|
-
*
|
|
3714
|
-
*
|
|
3715
|
-
*
|
|
3716
|
-
*
|
|
3717
|
-
* import { NodeContext } from "@effect/platform-node";
|
|
3718
|
-
* import { WorkspaceDiscovery, WorkspacesLive } from "workspaces-effect";
|
|
3719
|
-
*
|
|
3720
|
-
* const program = Effect.gen(function* () {
|
|
3721
|
-
* const discovery = yield* WorkspaceDiscovery;
|
|
3722
|
-
* const packages = yield* discovery.listPackages();
|
|
3723
|
-
* for (const pkg of packages) {
|
|
3724
|
-
* console.log(`${pkg.name} @ ${pkg.path}`);
|
|
3725
|
-
* }
|
|
3726
|
-
* });
|
|
3727
|
-
*
|
|
3728
|
-
* Effect.runPromise(
|
|
3729
|
-
* program.pipe(
|
|
3730
|
-
* Effect.provide(WorkspacesLive),
|
|
3731
|
-
* Effect.provide(NodeContext.layer),
|
|
3732
|
-
* )
|
|
3733
|
-
* );
|
|
3734
|
-
* ```
|
|
3735
|
-
*
|
|
3736
|
-
* @public
|
|
3737
|
-
*/
|
|
3738
|
-
declare class WorkspaceDiscovery extends WorkspaceDiscovery_base {}
|
|
3739
|
-
declare const WorkspaceDiscovery_base: Context.TagClass<WorkspaceDiscovery, "@spencerbeggs/workspaces-effect/WorkspaceDiscovery", {
|
|
3740
|
-
/**
|
|
3741
|
-
* List all workspace packages.
|
|
3742
|
-
*
|
|
3743
|
-
* Resolves workspace glob patterns and reads each matched `package.json`.
|
|
3744
|
-
*
|
|
3745
|
-
* @param cwd - Optional starting directory. When provided, the workspace
|
|
3746
|
-
* root is resolved fresh from `cwd` for this call (results cached per
|
|
3747
|
-
* resolved root). When omitted, uses the root that was eagerly resolved
|
|
3748
|
-
* from `process.cwd()` at layer construction time.
|
|
3749
|
-
* @returns An Effect that succeeds with a readonly array of
|
|
3750
|
-
* {@link WorkspacePackage} records, or fails with
|
|
3751
|
-
* {@link WorkspaceDiscoveryError} if workspace patterns cannot be resolved.
|
|
3752
|
-
*/
|
|
3753
|
-
readonly listPackages: (cwd?: string) => Effect.Effect<ReadonlyArray<WorkspacePackage>, WorkspaceDiscoveryError>;
|
|
3754
|
-
/**
|
|
3755
|
-
* Get a specific workspace package by name.
|
|
3756
|
-
*
|
|
3757
|
-
* @param name - The package name as declared in its `package.json` `name` field.
|
|
3758
|
-
* @param cwd - Optional starting directory. See {@link listPackages} for behavior.
|
|
3759
|
-
* @returns An Effect that succeeds with the matching {@link WorkspacePackage},
|
|
3760
|
-
* or fails with {@link PackageNotFoundError} if no workspace package has that
|
|
3761
|
-
* name, or {@link WorkspaceDiscoveryError} if discovery itself fails.
|
|
3762
|
-
*/
|
|
3763
|
-
readonly getPackage: (name: string, cwd?: string) => Effect.Effect<WorkspacePackage, PackageNotFoundError | WorkspaceDiscoveryError>;
|
|
3764
|
-
/**
|
|
3765
|
-
* Get a map of workspace-relative directory paths to packages.
|
|
3766
|
-
*
|
|
3767
|
-
* Useful for mapping lockfile importer keys to their workspace packages.
|
|
3768
|
-
* Built from `listPackages()` output and inherits its caching.
|
|
3769
|
-
*
|
|
3770
|
-
* @param cwd - Optional starting directory. See {@link listPackages} for behavior.
|
|
3771
|
-
* @returns An Effect that succeeds with a ReadonlyMap keyed by relativePath.
|
|
3772
|
-
*/
|
|
3773
|
-
readonly importerMap: (cwd?: string) => Effect.Effect<ReadonlyMap<string, WorkspacePackage>, WorkspaceDiscoveryError>;
|
|
3774
|
-
/**
|
|
3775
|
-
* Discard cached discovery results so the next {@link listPackages}
|
|
3776
|
-
* (and {@link getPackage} / {@link importerMap}, which build on it)
|
|
3777
|
-
* re-reads every `package.json` from disk.
|
|
3778
|
-
*
|
|
3779
|
-
* @remarks
|
|
3780
|
-
* `listPackages` memoizes its result per resolved workspace root for the
|
|
3781
|
-
* lifetime of the layer. That cache is correct for a static tree, but a
|
|
3782
|
-
* process that mutates `package.json` mid-run — for example running
|
|
3783
|
-
* `changeset version` to bump versions and then reading the new versions
|
|
3784
|
-
* back — would otherwise observe the pre-mutation snapshot. Call
|
|
3785
|
-
* `refresh` after such a mutation to force a re-scan.
|
|
3786
|
-
*
|
|
3787
|
-
* The resolved workspace root itself is not discarded (the root does not
|
|
3788
|
-
* move when package contents change), so the next call pays only the
|
|
3789
|
-
* package re-scan, not the root walk. `refresh` clears the cache for
|
|
3790
|
-
* every resolved root.
|
|
3791
|
-
*
|
|
3792
|
-
* @returns An Effect that clears the cache and succeeds with `void`.
|
|
3793
|
-
*/
|
|
3794
|
-
readonly refresh: () => Effect.Effect<void>;
|
|
3795
|
-
}>;
|
|
3796
|
-
/**
|
|
3797
|
-
* Emitted when workspace package discovery fails.
|
|
3798
|
-
*
|
|
3799
|
-
* @remarks
|
|
3800
|
-
* Raised by {@link WorkspaceDiscovery} when glob expansion of workspace
|
|
3801
|
-
* patterns or subsequent package.json reads fail. This can occur if patterns
|
|
3802
|
-
* in pnpm-workspace.yaml or the root package.json `workspaces` field resolve
|
|
3803
|
-
* to invalid or inaccessible directories.
|
|
3804
|
-
*
|
|
3805
|
-
* Fields:
|
|
3806
|
-
* - `root` — the workspace root path where discovery was attempted.
|
|
3807
|
-
* - `reason` — human-readable explanation of what went wrong.
|
|
3808
|
-
*
|
|
3809
|
-
* @example Catching the error
|
|
3810
|
-
* ```typescript
|
|
3811
|
-
* import { Effect } from "effect";
|
|
3812
|
-
* import type { WorkspaceDiscoveryError } from "workspaces-effect";
|
|
3813
|
-
* import { WorkspaceDiscovery, WorkspaceDiscoveryLive } from "workspaces-effect";
|
|
3814
|
-
*
|
|
3815
|
-
* const program = Effect.gen(function* () {
|
|
3816
|
-
* const discovery = yield* WorkspaceDiscovery;
|
|
3817
|
-
* return yield* discovery.discover("/workspace/root");
|
|
3818
|
-
* }).pipe(
|
|
3819
|
-
* Effect.catchTag("WorkspaceDiscoveryError", (e) =>
|
|
3820
|
-
* Effect.succeed(`Discovery failed at ${e.root}: ${e.reason}`)
|
|
3821
|
-
* )
|
|
3822
|
-
* );
|
|
3823
|
-
* ```
|
|
3824
|
-
*
|
|
3825
|
-
* @public
|
|
3826
|
-
*/
|
|
3827
|
-
declare class WorkspaceDiscoveryError extends WorkspaceDiscoveryErrorBase<{
|
|
3828
|
-
readonly root: string;
|
|
3829
|
-
readonly reason: string;
|
|
3830
|
-
}> {
|
|
3831
|
-
get message(): string;
|
|
3832
|
-
}
|
|
3833
|
-
/**
|
|
3834
|
-
* Base constant for {@link WorkspaceDiscoveryError}.
|
|
3835
|
-
*
|
|
3836
|
-
* @privateRemarks
|
|
3837
|
-
* Exported for api-extractor DTS bundling — the `_base` symbol from
|
|
3838
|
-
* `Data.TaggedError` must be visible in the generated .d.ts file.
|
|
3839
|
-
*
|
|
3840
|
-
* @internal
|
|
3841
|
-
*/
|
|
3842
|
-
declare const WorkspaceDiscoveryErrorBase: new <A extends Record<string, any> = {}>(args: VoidIfEmpty<{ readonly [P in keyof A as P extends "_tag" ? never : P]: A[P] }>) => YieldableError & {
|
|
3843
|
-
readonly _tag: "WorkspaceDiscoveryError";
|
|
3844
|
-
} & Readonly<A>;
|
|
3845
|
-
/**
|
|
3846
|
-
* A single workspace package within a monorepo.
|
|
3847
|
-
*
|
|
3848
|
-
* @remarks
|
|
3849
|
-
* Produced by {@link WorkspaceDiscovery} for each package found by expanding
|
|
3850
|
-
* the workspace glob patterns. Contains the parsed metadata from the
|
|
3851
|
-
* package's `package.json` plus its filesystem location.
|
|
3852
|
-
*
|
|
3853
|
-
* Fields:
|
|
3854
|
-
* - `name` — the package name (non-empty string).
|
|
3855
|
-
* - `version` — the package version string.
|
|
3856
|
-
* - `path` — absolute filesystem path to the package directory.
|
|
3857
|
-
* - `packageJsonPath` — absolute path to the package's `package.json` file.
|
|
3858
|
-
* - `relativePath` — path relative to the workspace root.
|
|
3859
|
-
* - `private` — whether the package is marked private (defaults to `false`).
|
|
3860
|
-
* - `dependencies` — production dependency map (defaults to `{}`).
|
|
3861
|
-
* - `devDependencies` — development dependency map (defaults to `{}`).
|
|
3862
|
-
* - `peerDependencies` — peer dependency map (defaults to `{}`).
|
|
3863
|
-
* - `optionalDependencies` — optional dependency map (defaults to `{}`).
|
|
3864
|
-
* - `publishConfig` — optional publishing configuration overrides.
|
|
3865
|
-
*
|
|
3866
|
-
* @example Creating a WorkspacePackage
|
|
3867
|
-
* ```typescript
|
|
3868
|
-
* import { WorkspacePackage } from "workspaces-effect";
|
|
3869
|
-
*
|
|
3870
|
-
* const pkg = new WorkspacePackage({
|
|
3871
|
-
* name: "@my-org/utils",
|
|
3872
|
-
* version: "1.0.0",
|
|
3873
|
-
* path: "/workspace/packages/utils",
|
|
3874
|
-
* packageJsonPath: "/workspace/packages/utils/package.json",
|
|
3875
|
-
* relativePath: "packages/utils",
|
|
3876
|
-
* });
|
|
3877
|
-
* ```
|
|
3878
|
-
*
|
|
3879
|
-
* @public
|
|
3841
|
+
/**
|
|
3842
|
+
* A single workspace package within a monorepo.
|
|
3843
|
+
*
|
|
3844
|
+
* @remarks
|
|
3845
|
+
* Produced by {@link WorkspaceDiscovery} for each package found by expanding
|
|
3846
|
+
* the workspace glob patterns. Contains the parsed metadata from the
|
|
3847
|
+
* package's `package.json` plus its filesystem location.
|
|
3848
|
+
*
|
|
3849
|
+
* Fields:
|
|
3850
|
+
* - `name` — the package name (non-empty string).
|
|
3851
|
+
* - `version` — the package version string.
|
|
3852
|
+
* - `path` — absolute filesystem path to the package directory.
|
|
3853
|
+
* - `packageJsonPath` — absolute path to the package's `package.json` file.
|
|
3854
|
+
* - `relativePath` — path relative to the workspace root.
|
|
3855
|
+
* - `private` — whether the package is marked private (defaults to `false`).
|
|
3856
|
+
* - `dependencies` — production dependency map (defaults to `{}`).
|
|
3857
|
+
* - `devDependencies` — development dependency map (defaults to `{}`).
|
|
3858
|
+
* - `peerDependencies` — peer dependency map (defaults to `{}`).
|
|
3859
|
+
* - `optionalDependencies` — optional dependency map (defaults to `{}`).
|
|
3860
|
+
* - `publishConfig` — optional publishing configuration overrides.
|
|
3861
|
+
*
|
|
3862
|
+
* @example Creating a WorkspacePackage
|
|
3863
|
+
* ```typescript
|
|
3864
|
+
* import { WorkspacePackage } from "workspaces-effect";
|
|
3865
|
+
*
|
|
3866
|
+
* const pkg = new WorkspacePackage({
|
|
3867
|
+
* name: "@my-org/utils",
|
|
3868
|
+
* version: "1.0.0",
|
|
3869
|
+
* path: "/workspace/packages/utils",
|
|
3870
|
+
* packageJsonPath: "/workspace/packages/utils/package.json",
|
|
3871
|
+
* relativePath: "packages/utils",
|
|
3872
|
+
* });
|
|
3873
|
+
* ```
|
|
3874
|
+
*
|
|
3875
|
+
* @public
|
|
3880
3876
|
*/
|
|
3881
3877
|
declare class WorkspacePackage extends WorkspacePackage_base {
|
|
3882
3878
|
get isRootWorkspace(): boolean;
|
|
@@ -3891,12 +3887,12 @@ declare class WorkspacePackage extends WorkspacePackage_base {
|
|
|
3891
3887
|
hasAnyDependencyOn(name: string): boolean;
|
|
3892
3888
|
dependencyVersion(name: string): Option.Option<string>;
|
|
3893
3889
|
matchesDependency(pattern: string): boolean;
|
|
3894
|
-
/**
|
|
3895
|
-
* Compare two WorkspacePackage dependency snapshots.
|
|
3896
|
-
*
|
|
3897
|
-
* Compares across all dependency types combined. A dependency that moves
|
|
3898
|
-
* between categories (e.g. from `dependencies` to `peerDependencies`) at
|
|
3899
|
-
* the same version will not appear in the diff.
|
|
3890
|
+
/**
|
|
3891
|
+
* Compare two WorkspacePackage dependency snapshots.
|
|
3892
|
+
*
|
|
3893
|
+
* Compares across all dependency types combined. A dependency that moves
|
|
3894
|
+
* between categories (e.g. from `dependencies` to `peerDependencies`) at
|
|
3895
|
+
* the same version will not appear in the diff.
|
|
3900
3896
|
*/
|
|
3901
3897
|
dependencyDiff(other: WorkspacePackage): DependencyDiff;
|
|
3902
3898
|
static hasDependency: {
|
|
@@ -3933,15 +3929,167 @@ declare class WorkspacePackage extends WorkspacePackage_base {
|
|
|
3933
3929
|
};
|
|
3934
3930
|
static readPackageJson: (self: WorkspacePackage) => Effect.Effect<PackageJsonType, PackageJsonParseError, FileSystem.FileSystem>;
|
|
3935
3931
|
}
|
|
3936
|
-
|
|
3932
|
+
//#endregion
|
|
3933
|
+
//#region src/services/WorkspaceDiscovery.d.ts
|
|
3934
|
+
declare const WorkspaceDiscovery_base: Context.TagClass<WorkspaceDiscovery, "@spencerbeggs/workspaces-effect/WorkspaceDiscovery", {
|
|
3935
|
+
/**
|
|
3936
|
+
* List all workspace packages.
|
|
3937
|
+
*
|
|
3938
|
+
* Resolves workspace glob patterns and reads each matched `package.json`.
|
|
3939
|
+
*
|
|
3940
|
+
* @param cwd - Optional starting directory. When provided, the workspace
|
|
3941
|
+
* root is resolved fresh from `cwd` for this call (results cached per
|
|
3942
|
+
* resolved root). When omitted, uses the root that was eagerly resolved
|
|
3943
|
+
* from `process.cwd()` at layer construction time.
|
|
3944
|
+
* @returns An Effect that succeeds with a readonly array of
|
|
3945
|
+
* {@link WorkspacePackage} records, or fails with
|
|
3946
|
+
* {@link WorkspaceDiscoveryError} if workspace patterns cannot be resolved.
|
|
3947
|
+
*/
|
|
3948
|
+
readonly listPackages: (cwd?: string) => Effect.Effect<ReadonlyArray<WorkspacePackage>, WorkspaceDiscoveryError>;
|
|
3949
|
+
/**
|
|
3950
|
+
* Get a specific workspace package by name.
|
|
3951
|
+
*
|
|
3952
|
+
* @param name - The package name as declared in its `package.json` `name` field.
|
|
3953
|
+
* @param cwd - Optional starting directory. See {@link listPackages} for behavior.
|
|
3954
|
+
* @returns An Effect that succeeds with the matching {@link WorkspacePackage},
|
|
3955
|
+
* or fails with {@link PackageNotFoundError} if no workspace package has that
|
|
3956
|
+
* name, or {@link WorkspaceDiscoveryError} if discovery itself fails.
|
|
3957
|
+
*/
|
|
3958
|
+
readonly getPackage: (name: string, cwd?: string) => Effect.Effect<WorkspacePackage, PackageNotFoundError | WorkspaceDiscoveryError>;
|
|
3959
|
+
/**
|
|
3960
|
+
* Get a map of workspace-relative directory paths to packages.
|
|
3961
|
+
*
|
|
3962
|
+
* Useful for mapping lockfile importer keys to their workspace packages.
|
|
3963
|
+
* Built from `listPackages()` output and inherits its caching.
|
|
3964
|
+
*
|
|
3965
|
+
* @param cwd - Optional starting directory. See {@link listPackages} for behavior.
|
|
3966
|
+
* @returns An Effect that succeeds with a ReadonlyMap keyed by relativePath.
|
|
3967
|
+
*/
|
|
3968
|
+
readonly importerMap: (cwd?: string) => Effect.Effect<ReadonlyMap<string, WorkspacePackage>, WorkspaceDiscoveryError>;
|
|
3969
|
+
/**
|
|
3970
|
+
* Discard cached discovery results so the next {@link listPackages}
|
|
3971
|
+
* (and {@link getPackage} / {@link importerMap}, which build on it)
|
|
3972
|
+
* re-reads every `package.json` from disk.
|
|
3973
|
+
*
|
|
3974
|
+
* @remarks
|
|
3975
|
+
* `listPackages` memoizes its result per resolved workspace root for the
|
|
3976
|
+
* lifetime of the layer. That cache is correct for a static tree, but a
|
|
3977
|
+
* process that mutates `package.json` mid-run — for example running
|
|
3978
|
+
* `changeset version` to bump versions and then reading the new versions
|
|
3979
|
+
* back — would otherwise observe the pre-mutation snapshot. Call
|
|
3980
|
+
* `refresh` after such a mutation to force a re-scan.
|
|
3981
|
+
*
|
|
3982
|
+
* The resolved workspace root itself is not discarded (the root does not
|
|
3983
|
+
* move when package contents change), so the next call pays only the
|
|
3984
|
+
* package re-scan, not the root walk. `refresh` clears the cache for
|
|
3985
|
+
* every resolved root.
|
|
3986
|
+
*
|
|
3987
|
+
* @returns An Effect that clears the cache and succeeds with `void`.
|
|
3988
|
+
*/
|
|
3989
|
+
readonly refresh: () => Effect.Effect<void>;
|
|
3990
|
+
}>;
|
|
3991
|
+
/**
|
|
3992
|
+
* Service for discovering workspace packages in a monorepo.
|
|
3993
|
+
*
|
|
3994
|
+
* Reads workspace patterns from the PM-specific config (e.g., `pnpm-workspace.yaml`,
|
|
3995
|
+
* `package.json` `workspaces` field), resolves glob patterns against the filesystem,
|
|
3996
|
+
* and reads each matched `package.json` to produce {@link WorkspacePackage} records.
|
|
3997
|
+
*
|
|
3998
|
+
* @remarks
|
|
3999
|
+
* WorkspaceDiscovery is the last service in the Discovery group and the primary
|
|
4000
|
+
* data source for downstream services. DependencyGraph, TopologicalSorter,
|
|
4001
|
+
* PackageResolver, and ChangeDetector all depend on the package list it produces.
|
|
4002
|
+
*
|
|
4003
|
+
* The live layer (`WorkspaceDiscoveryLive`) depends on `WorkspaceRoot` and
|
|
4004
|
+
* `PackageManagerDetector`. It requires `FileSystem` and `Path` from
|
|
4005
|
+
* `@effect/platform`. Use `WorkspacesLive` or `WorkspacesFullLive` to get all
|
|
4006
|
+
* wiring handled automatically.
|
|
4007
|
+
*
|
|
4008
|
+
* @privateRemarks
|
|
4009
|
+
* Uses the class-based `Context.Tag` pattern. The internal tag identifier is
|
|
4010
|
+
* `@spencerbeggs/workspaces-effect/WorkspaceDiscovery`. Dependencies (WorkspaceRoot,
|
|
4011
|
+
* PackageManagerDetector) are resolved at layer construction time so that service
|
|
4012
|
+
* methods have `R = never`.
|
|
4013
|
+
*
|
|
4014
|
+
* @example Listing all workspace packages
|
|
4015
|
+
* ```typescript
|
|
4016
|
+
* import { Effect } from "effect";
|
|
4017
|
+
* import { NodeContext } from "@effect/platform-node";
|
|
4018
|
+
* import { WorkspaceDiscovery, WorkspacesLive } from "workspaces-effect";
|
|
4019
|
+
*
|
|
4020
|
+
* const program = Effect.gen(function* () {
|
|
4021
|
+
* const discovery = yield* WorkspaceDiscovery;
|
|
4022
|
+
* const packages = yield* discovery.listPackages();
|
|
4023
|
+
* for (const pkg of packages) {
|
|
4024
|
+
* console.log(`${pkg.name} @ ${pkg.path}`);
|
|
4025
|
+
* }
|
|
4026
|
+
* });
|
|
4027
|
+
*
|
|
4028
|
+
* Effect.runPromise(
|
|
4029
|
+
* program.pipe(
|
|
4030
|
+
* Effect.provide(WorkspacesLive),
|
|
4031
|
+
* Effect.provide(NodeContext.layer),
|
|
4032
|
+
* )
|
|
4033
|
+
* );
|
|
4034
|
+
* ```
|
|
4035
|
+
*
|
|
4036
|
+
* @public
|
|
4037
|
+
*/
|
|
4038
|
+
declare class WorkspaceDiscovery extends WorkspaceDiscovery_base {} //#endregion
|
|
4039
|
+
//#region src/services/WorkspaceRoot.d.ts
|
|
4040
|
+
//#endregion
|
|
4041
|
+
//#region src/schemas/CatalogSet.d.ts
|
|
4042
|
+
declare const CatalogSet_base: Schema.Class<CatalogSet, {
|
|
4043
|
+
entries: Schema.Record$<typeof Schema.String, Schema.Record$<typeof Schema.String, typeof Schema.String>>;
|
|
4044
|
+
}, Schema.Struct.Encoded<{
|
|
4045
|
+
entries: Schema.Record$<typeof Schema.String, Schema.Record$<typeof Schema.String, typeof Schema.String>>;
|
|
4046
|
+
}>, never, {
|
|
4047
|
+
readonly entries: {
|
|
4048
|
+
readonly [x: string]: {
|
|
4049
|
+
readonly [x: string]: string;
|
|
4050
|
+
};
|
|
4051
|
+
};
|
|
4052
|
+
}, {}, {}>;
|
|
4053
|
+
/**
|
|
4054
|
+
* An immutable, fully-normalized catalog collection with the one
|
|
4055
|
+
* resolution semantic shared by live and point-in-time resolution.
|
|
4056
|
+
*
|
|
4057
|
+
* @public
|
|
4058
|
+
*/
|
|
4059
|
+
declare class CatalogSet extends CatalogSet_base {
|
|
4060
|
+
/** An empty catalog set. */
|
|
4061
|
+
static empty(): CatalogSet;
|
|
4062
|
+
/** Wrap a pnpm `Catalogs` map, dropping undefined entries. */
|
|
4063
|
+
static fromCatalogs(catalogs: Catalogs): CatalogSet;
|
|
4064
|
+
/** Parse the `catalog:`/`catalogs:` sections of a pnpm-workspace.yaml text. */
|
|
4065
|
+
static fromWorkspaceYaml(text: string): Effect.Effect<CatalogSet, CatalogAssemblyError>;
|
|
4066
|
+
/**
|
|
4067
|
+
* Normalize a pnpm lockfile `catalogs:` section — entries are either a
|
|
4068
|
+
* specifier string or a `{ specifier, version }` object.
|
|
4069
|
+
*/
|
|
4070
|
+
static fromLockfileCatalogs(raw: unknown): CatalogSet;
|
|
4071
|
+
/** Merge sets; later sets win per dependency within a catalog. */
|
|
4072
|
+
static merge(...sets: ReadonlyArray<CatalogSet>): CatalogSet;
|
|
4073
|
+
/** View as the pnpm `Catalogs` shape. */
|
|
4074
|
+
toCatalogs(): Catalogs;
|
|
4075
|
+
/**
|
|
4076
|
+
* Resolve a `catalog:` specifier to its concrete range. `Option.none`
|
|
4077
|
+
* for non-catalog specifiers and unresolved catalog entries.
|
|
4078
|
+
*
|
|
4079
|
+
* @remarks
|
|
4080
|
+
* Deliberately contrasts with `CatalogResolver.resolveSpecifier`: this
|
|
4081
|
+
* method is catalog-only and returns `Option.none` on unresolvable refs,
|
|
4082
|
+
* whereas the live service also handles `workspace:` specifiers and fails
|
|
4083
|
+
* with a typed `CatalogResolutionError`. Both route through
|
|
4084
|
+
* `resolveManifest`, which is the single resolution semantic.
|
|
4085
|
+
*/
|
|
4086
|
+
resolveSpecifier(dependency: string, specifier: string): Option.Option<string>;
|
|
4087
|
+
} //#endregion
|
|
4088
|
+
//#region src/schemas/WorkspaceStateSnapshot.d.ts
|
|
4089
|
+
declare const PackageStateSnapshot_base: Schema.Class<PackageStateSnapshot, {
|
|
3937
4090
|
name: typeof Schema.NonEmptyString;
|
|
3938
4091
|
version: typeof Schema.String;
|
|
3939
|
-
path: typeof Schema.NonEmptyString;
|
|
3940
|
-
packageJsonPath: typeof Schema.NonEmptyString;
|
|
3941
4092
|
relativePath: typeof Schema.String;
|
|
3942
|
-
private: Schema.optionalWith<typeof Schema.Boolean, {
|
|
3943
|
-
default: () => false;
|
|
3944
|
-
}>;
|
|
3945
4093
|
dependencies: Schema.optionalWith<Schema.Record$<typeof Schema.String, typeof Schema.String>, {
|
|
3946
4094
|
default: () => {};
|
|
3947
4095
|
}>;
|
|
@@ -3954,16 +4102,10 @@ declare const WorkspacePackage_base: Schema.Class<WorkspacePackage, {
|
|
|
3954
4102
|
optionalDependencies: Schema.optionalWith<Schema.Record$<typeof Schema.String, typeof Schema.String>, {
|
|
3955
4103
|
default: () => {};
|
|
3956
4104
|
}>;
|
|
3957
|
-
publishConfig: Schema.optional<typeof PublishConfig>;
|
|
3958
4105
|
}, Schema.Struct.Encoded<{
|
|
3959
4106
|
name: typeof Schema.NonEmptyString;
|
|
3960
4107
|
version: typeof Schema.String;
|
|
3961
|
-
path: typeof Schema.NonEmptyString;
|
|
3962
|
-
packageJsonPath: typeof Schema.NonEmptyString;
|
|
3963
4108
|
relativePath: typeof Schema.String;
|
|
3964
|
-
private: Schema.optionalWith<typeof Schema.Boolean, {
|
|
3965
|
-
default: () => false;
|
|
3966
|
-
}>;
|
|
3967
4109
|
dependencies: Schema.optionalWith<Schema.Record$<typeof Schema.String, typeof Schema.String>, {
|
|
3968
4110
|
default: () => {};
|
|
3969
4111
|
}>;
|
|
@@ -3976,56 +4118,354 @@ declare const WorkspacePackage_base: Schema.Class<WorkspacePackage, {
|
|
|
3976
4118
|
optionalDependencies: Schema.optionalWith<Schema.Record$<typeof Schema.String, typeof Schema.String>, {
|
|
3977
4119
|
default: () => {};
|
|
3978
4120
|
}>;
|
|
3979
|
-
publishConfig: Schema.optional<typeof PublishConfig>;
|
|
3980
4121
|
}>, never, {
|
|
3981
|
-
readonly publishConfig?: PublishConfig | undefined;
|
|
3982
|
-
} & {
|
|
3983
4122
|
readonly dependencies?: {
|
|
3984
4123
|
readonly [x: string]: string;
|
|
3985
|
-
};
|
|
4124
|
+
} | undefined;
|
|
3986
4125
|
} & {
|
|
3987
4126
|
readonly devDependencies?: {
|
|
3988
4127
|
readonly [x: string]: string;
|
|
3989
|
-
};
|
|
4128
|
+
} | undefined;
|
|
3990
4129
|
} & {
|
|
3991
4130
|
readonly optionalDependencies?: {
|
|
3992
4131
|
readonly [x: string]: string;
|
|
3993
|
-
};
|
|
4132
|
+
} | undefined;
|
|
3994
4133
|
} & {
|
|
3995
4134
|
readonly peerDependencies?: {
|
|
3996
4135
|
readonly [x: string]: string;
|
|
3997
|
-
};
|
|
3998
|
-
} & {
|
|
3999
|
-
readonly private?: boolean;
|
|
4136
|
+
} | undefined;
|
|
4000
4137
|
} & {
|
|
4001
4138
|
readonly name: string;
|
|
4002
|
-
} & {
|
|
4003
|
-
readonly packageJsonPath: string;
|
|
4004
|
-
} & {
|
|
4005
|
-
readonly path: string;
|
|
4006
4139
|
} & {
|
|
4007
4140
|
readonly relativePath: string;
|
|
4008
4141
|
} & {
|
|
4009
4142
|
readonly version: string;
|
|
4010
4143
|
}, {}, {}>;
|
|
4011
|
-
/**
|
|
4012
|
-
*
|
|
4013
|
-
*
|
|
4014
|
-
* @
|
|
4015
|
-
|
|
4016
|
-
|
|
4017
|
-
|
|
4018
|
-
|
|
4019
|
-
|
|
4020
|
-
|
|
4021
|
-
|
|
4022
|
-
|
|
4023
|
-
|
|
4024
|
-
|
|
4025
|
-
|
|
4026
|
-
|
|
4027
|
-
|
|
4028
|
-
|
|
4144
|
+
/**
|
|
4145
|
+
* One workspace package as it existed at a point in time.
|
|
4146
|
+
*
|
|
4147
|
+
* @public
|
|
4148
|
+
*/
|
|
4149
|
+
declare class PackageStateSnapshot extends PackageStateSnapshot_base {}
|
|
4150
|
+
declare const WorkspaceStateSnapshot_base: Schema.Class<WorkspaceStateSnapshot, {
|
|
4151
|
+
packages: Schema.Array$<typeof PackageStateSnapshot>;
|
|
4152
|
+
catalogs: typeof CatalogSet;
|
|
4153
|
+
}, Schema.Struct.Encoded<{
|
|
4154
|
+
packages: Schema.Array$<typeof PackageStateSnapshot>;
|
|
4155
|
+
catalogs: typeof CatalogSet;
|
|
4156
|
+
}>, never, {
|
|
4157
|
+
readonly catalogs: CatalogSet;
|
|
4158
|
+
} & {
|
|
4159
|
+
readonly packages: readonly PackageStateSnapshot[];
|
|
4160
|
+
}, {}, {}>;
|
|
4161
|
+
/**
|
|
4162
|
+
* The full workspace state at a point in time: every package plus that
|
|
4163
|
+
* moment's assembled catalogs. `resolve` answers "what did this specifier
|
|
4164
|
+
* mean HERE" — catalog: against this snapshot's catalogs, workspace:
|
|
4165
|
+
* against this snapshot's package versions.
|
|
4166
|
+
*
|
|
4167
|
+
* @public
|
|
4168
|
+
*/
|
|
4169
|
+
declare class WorkspaceStateSnapshot extends WorkspaceStateSnapshot_base {
|
|
4170
|
+
#private;
|
|
4171
|
+
/**
|
|
4172
|
+
* name → version map for workspace: resolution. Stable reference.
|
|
4173
|
+
*
|
|
4174
|
+
* @remarks
|
|
4175
|
+
* The returned record is this instance's memo, built once and reused by
|
|
4176
|
+
* every subsequent {@link resolve} call. Treat it as read-only -- mutating
|
|
4177
|
+
* it corrupts resolution for the lifetime of this snapshot.
|
|
4178
|
+
*/
|
|
4179
|
+
get versions(): Record<string, string>;
|
|
4180
|
+
/** Find a package snapshot by name (O(1) after the first call). */
|
|
4181
|
+
package(name: string): Option.Option<PackageStateSnapshot>;
|
|
4182
|
+
/**
|
|
4183
|
+
* Resolve a catalog:/workspace: specifier against THIS snapshot.
|
|
4184
|
+
* `Option.none` for plain specifiers and unresolvable references.
|
|
4185
|
+
*/
|
|
4186
|
+
resolve(dependency: string, specifier: string): Option.Option<string>;
|
|
4187
|
+
} //#endregion
|
|
4188
|
+
//#region src/services/PointInTimeWorkspace.d.ts
|
|
4189
|
+
/**
|
|
4190
|
+
* The umbrella error union covering both {@link PointInTimeWorkspace}
|
|
4191
|
+
* methods: {@link PointInTimeAtError} (raised by `at`) unioned with
|
|
4192
|
+
* {@link PointInTimeWorktreeError} (raised by `worktree`).
|
|
4193
|
+
*
|
|
4194
|
+
* @remarks
|
|
4195
|
+
* - {@link GitReadError} — a `git show`/`git ls-tree` invocation failed for a
|
|
4196
|
+
* reason other than "path absent at this ref" (absent paths degrade to
|
|
4197
|
+
* `Option.none`, never an error). `at`-only.
|
|
4198
|
+
* - {@link CatalogAssemblyError} — the `pnpm-workspace.yaml` at the ref (or on
|
|
4199
|
+
* disk) is malformed YAML. A malformed *lockfile* never fails; it degrades to
|
|
4200
|
+
* an empty catalog set.
|
|
4201
|
+
* - {@link WorkspaceRootNotFoundError} — the workspace root could not be
|
|
4202
|
+
* located walking up from `options.cwd` (or `process.cwd()` when omitted).
|
|
4203
|
+
* - {@link WorkspaceDiscoveryError} — `worktree` failed to enumerate the live
|
|
4204
|
+
* packages via `WorkspaceDiscovery`. `worktree`-only.
|
|
4205
|
+
*
|
|
4206
|
+
* @public
|
|
4207
|
+
*/
|
|
4208
|
+
type PointInTimeReadError = PointInTimeAtError | PointInTimeWorktreeError;
|
|
4209
|
+
/**
|
|
4210
|
+
* Options accepted by both {@link PointInTimeWorkspace} methods.
|
|
4211
|
+
*
|
|
4212
|
+
* @public
|
|
4213
|
+
*/
|
|
4214
|
+
interface PointInTimeOptions {
|
|
4215
|
+
/**
|
|
4216
|
+
* Starting directory for workspace-root resolution. The root is found by
|
|
4217
|
+
* walking UP from here (same semantics as `WorkspaceDiscovery`); when
|
|
4218
|
+
* omitted, resolution starts from `process.cwd()`.
|
|
4219
|
+
*/
|
|
4220
|
+
readonly cwd?: string;
|
|
4221
|
+
}
|
|
4222
|
+
/**
|
|
4223
|
+
* Errors `at` can raise. `at` never enumerates the live filesystem, so
|
|
4224
|
+
* {@link WorkspaceDiscoveryError} cannot occur.
|
|
4225
|
+
*
|
|
4226
|
+
* @public
|
|
4227
|
+
*/
|
|
4228
|
+
type PointInTimeAtError = GitReadError | CatalogAssemblyError | WorkspaceRootNotFoundError;
|
|
4229
|
+
/**
|
|
4230
|
+
* Errors `worktree` can raise. `worktree` never invokes git, so
|
|
4231
|
+
* {@link GitReadError} cannot occur.
|
|
4232
|
+
*
|
|
4233
|
+
* @public
|
|
4234
|
+
*/
|
|
4235
|
+
type PointInTimeWorktreeError = CatalogAssemblyError | WorkspaceRootNotFoundError | WorkspaceDiscoveryError;
|
|
4236
|
+
declare const PointInTimeWorkspace_base: Context.TagClass<PointInTimeWorkspace, "@spencerbeggs/workspaces-effect/PointInTimeWorkspace", {
|
|
4237
|
+
/**
|
|
4238
|
+
* Workspace state as of a git ref.
|
|
4239
|
+
*
|
|
4240
|
+
* Reads `pnpm-workspace.yaml`, `pnpm-lock.yaml`, and each package's
|
|
4241
|
+
* `package.json` at `ref` via `git show`/`git ls-tree`; packages absent at
|
|
4242
|
+
* the ref are skipped. Cached per `(resolved root, ref)`.
|
|
4243
|
+
*
|
|
4244
|
+
* @param ref - Any git ref (SHA, branch, tag) resolvable in the repo.
|
|
4245
|
+
* @param options - Optional {@link PointInTimeOptions}; `options.cwd` is a
|
|
4246
|
+
* starting directory to walk UP from when resolving the workspace root
|
|
4247
|
+
* (same semantics as `WorkspaceDiscovery`) — when omitted, resolution
|
|
4248
|
+
* starts from `process.cwd()`.
|
|
4249
|
+
* @returns An Effect that succeeds with the {@link WorkspaceStateSnapshot}
|
|
4250
|
+
* at the ref, or fails with {@link PointInTimeAtError}.
|
|
4251
|
+
*/
|
|
4252
|
+
readonly at: (ref: string, options?: PointInTimeOptions) => Effect.Effect<WorkspaceStateSnapshot, PointInTimeAtError>;
|
|
4253
|
+
/**
|
|
4254
|
+
* Workspace state of the live working tree (staged + unstaged edits).
|
|
4255
|
+
*
|
|
4256
|
+
* Enumerates packages via `WorkspaceDiscovery` and reads catalogs from the
|
|
4257
|
+
* on-disk `pnpm-workspace.yaml` and `pnpm-lock.yaml`. Uncached.
|
|
4258
|
+
*
|
|
4259
|
+
* @param options - Optional {@link PointInTimeOptions}; `options.cwd` is a
|
|
4260
|
+
* starting directory to walk UP from when resolving the workspace root
|
|
4261
|
+
* (same semantics as `WorkspaceDiscovery`) — when omitted, resolution
|
|
4262
|
+
* starts from `process.cwd()`.
|
|
4263
|
+
* @returns An Effect that succeeds with the live {@link WorkspaceStateSnapshot},
|
|
4264
|
+
* or fails with {@link PointInTimeWorktreeError}.
|
|
4265
|
+
*/
|
|
4266
|
+
readonly worktree: (options?: PointInTimeOptions) => Effect.Effect<WorkspaceStateSnapshot, PointInTimeWorktreeError>;
|
|
4267
|
+
}>;
|
|
4268
|
+
/**
|
|
4269
|
+
* Service for reading a monorepo's workspace state at a specific moment: any
|
|
4270
|
+
* git ref (via `git show`/`git ls-tree`, without checking the ref out) or the
|
|
4271
|
+
* live working tree (via `WorkspaceDiscovery`).
|
|
4272
|
+
*
|
|
4273
|
+
* @remarks
|
|
4274
|
+
* Each snapshot carries that moment's packages plus its assembled pnpm catalog
|
|
4275
|
+
* set, so `catalog:`/`workspace:` specifiers resolve against the state as it
|
|
4276
|
+
* existed *then* — not against the current working tree. Catalog precedence is
|
|
4277
|
+
* lockfile-then-inline (inline `pnpm-workspace.yaml` catalogs win).
|
|
4278
|
+
*
|
|
4279
|
+
* The live layer ({@link PointInTimeWorkspaceLive}) resolves `WorkspaceRoot`,
|
|
4280
|
+
* `WorkspaceDiscovery`, `CommandExecutor`, `FileSystem`, and `Path` at layer
|
|
4281
|
+
* construction so both methods have `R = never`. Use `WorkspacesFullLive` to
|
|
4282
|
+
* get all wiring handled automatically.
|
|
4283
|
+
*
|
|
4284
|
+
* @privateRemarks
|
|
4285
|
+
* Uses the class-based `Context.Tag` pattern. The internal tag identifier is
|
|
4286
|
+
* `@spencerbeggs/workspaces-effect/PointInTimeWorkspace`.
|
|
4287
|
+
*
|
|
4288
|
+
* @see {@link PointInTimeWorkspaceLive} for the live implementation.
|
|
4289
|
+
*
|
|
4290
|
+
* @public
|
|
4291
|
+
*/
|
|
4292
|
+
declare class PointInTimeWorkspace extends PointInTimeWorkspace_base {} //#endregion
|
|
4293
|
+
//#region src/layers/PointInTimeWorkspaceLive.d.ts
|
|
4294
|
+
/**
|
|
4295
|
+
* Convenience type alias for the {@link PointInTimeWorkspaceLive} layer signature.
|
|
4296
|
+
*
|
|
4297
|
+
* @public
|
|
4298
|
+
*/
|
|
4299
|
+
//#endregion
|
|
4300
|
+
//#region src/schemas/publish.d.ts
|
|
4301
|
+
declare const PublishTarget_base: Schema.Class<PublishTarget, {
|
|
4302
|
+
name: typeof Schema.NonEmptyString;
|
|
4303
|
+
registry: typeof Schema.NonEmptyString;
|
|
4304
|
+
directory: typeof Schema.String;
|
|
4305
|
+
access: Schema.Literal<["public", "restricted"]>;
|
|
4306
|
+
provenance: Schema.optionalWith<typeof Schema.Boolean, {
|
|
4307
|
+
default: () => false;
|
|
4308
|
+
}>;
|
|
4309
|
+
}, Schema.Struct.Encoded<{
|
|
4310
|
+
name: typeof Schema.NonEmptyString;
|
|
4311
|
+
registry: typeof Schema.NonEmptyString;
|
|
4312
|
+
directory: typeof Schema.String;
|
|
4313
|
+
access: Schema.Literal<["public", "restricted"]>;
|
|
4314
|
+
provenance: Schema.optionalWith<typeof Schema.Boolean, {
|
|
4315
|
+
default: () => false;
|
|
4316
|
+
}>;
|
|
4317
|
+
}>, never, {
|
|
4318
|
+
readonly provenance?: boolean | undefined;
|
|
4319
|
+
} & {
|
|
4320
|
+
readonly access: "public" | "restricted";
|
|
4321
|
+
} & {
|
|
4322
|
+
readonly directory: string;
|
|
4323
|
+
} & {
|
|
4324
|
+
readonly name: string;
|
|
4325
|
+
} & {
|
|
4326
|
+
readonly registry: string;
|
|
4327
|
+
}, {}, {}>;
|
|
4328
|
+
/**
|
|
4329
|
+
* A single publish target for a workspace package.
|
|
4330
|
+
*
|
|
4331
|
+
* @remarks
|
|
4332
|
+
* Represents the resolved publishing configuration for a workspace package,
|
|
4333
|
+
* combining defaults with any overrides from the package's `publishConfig`
|
|
4334
|
+
* field. Used to determine where and how each package should be published.
|
|
4335
|
+
*
|
|
4336
|
+
* Fields:
|
|
4337
|
+
* - `name` — the package name (non-empty string).
|
|
4338
|
+
* - `registry` — the target registry URL (e.g., `"https://registry.npmjs.org"`).
|
|
4339
|
+
* - `directory` — the directory to publish (empty string means the package root).
|
|
4340
|
+
* - `access` — `"public"` or `"restricted"` (scoped package visibility).
|
|
4341
|
+
* - `provenance` — whether to publish with provenance attestation (defaults to `false`).
|
|
4342
|
+
*
|
|
4343
|
+
* @example Creating a PublishTarget
|
|
4344
|
+
* ```typescript
|
|
4345
|
+
* import { PublishTarget } from "workspaces-effect";
|
|
4346
|
+
*
|
|
4347
|
+
* const target = new PublishTarget({
|
|
4348
|
+
* name: "@my-org/utils",
|
|
4349
|
+
* registry: "https://registry.npmjs.org",
|
|
4350
|
+
* directory: "dist/npm",
|
|
4351
|
+
* access: "public",
|
|
4352
|
+
* });
|
|
4353
|
+
* ```
|
|
4354
|
+
*
|
|
4355
|
+
* @public
|
|
4356
|
+
*/
|
|
4357
|
+
declare class PublishTarget extends PublishTarget_base {} //#endregion
|
|
4358
|
+
//#region src/services/PublishabilityDetector.d.ts
|
|
4359
|
+
declare const PublishabilityDetector_base: Context.TagClass<PublishabilityDetector, "@spencerbeggs/workspaces-effect/PublishabilityDetector", {
|
|
4360
|
+
/**
|
|
4361
|
+
* Detect publish targets for a workspace package.
|
|
4362
|
+
*
|
|
4363
|
+
* Analyzes the package's `package.json` fields to determine if and where
|
|
4364
|
+
* it can be published.
|
|
4365
|
+
*
|
|
4366
|
+
* @param pkg - The {@link WorkspacePackage} to analyze.
|
|
4367
|
+
* @param root - Absolute path to the workspace root directory.
|
|
4368
|
+
* @returns An Effect that succeeds with a readonly array of
|
|
4369
|
+
* {@link PublishTarget} records. An empty array indicates the package is
|
|
4370
|
+
* not publishable. Never fails.
|
|
4371
|
+
*/
|
|
4372
|
+
readonly detect: (pkg: WorkspacePackage, root: string) => Effect.Effect<ReadonlyArray<PublishTarget>>;
|
|
4373
|
+
}>;
|
|
4374
|
+
/**
|
|
4375
|
+
* Service for detecting whether a workspace package is publishable and
|
|
4376
|
+
* identifying its publish targets (npm, GitHub Packages, etc.).
|
|
4377
|
+
*
|
|
4378
|
+
* Inspects `package.json` fields such as `private`, `publishConfig`, and
|
|
4379
|
+
* `repository` to determine publishability and target registries.
|
|
4380
|
+
*
|
|
4381
|
+
* @remarks
|
|
4382
|
+
* PublishabilityDetector is part of the Configuration and Lockfiles service
|
|
4383
|
+
* group. It is a pure service with no dependencies on other services — it
|
|
4384
|
+
* operates solely on the {@link WorkspacePackage} data and the workspace root
|
|
4385
|
+
* path passed to it.
|
|
4386
|
+
*
|
|
4387
|
+
* A package is considered publishable when `private` is not `true` and it has a
|
|
4388
|
+
* `name` and `version`. The returned {@link PublishTarget} array describes where
|
|
4389
|
+
* the package would be published (e.g., npmjs.org, GitHub Packages) based on
|
|
4390
|
+
* `publishConfig.registry` and other signals.
|
|
4391
|
+
*
|
|
4392
|
+
* The live layer (`PublishabilityDetectorLive`) is a pure layer with no
|
|
4393
|
+
* dependencies — it can be provided standalone or via `WorkspacesLive` /
|
|
4394
|
+
* `WorkspacesFullLive`.
|
|
4395
|
+
*
|
|
4396
|
+
* @privateRemarks
|
|
4397
|
+
* Uses the class-based `Context.Tag` pattern. The internal tag identifier is
|
|
4398
|
+
* `@spencerbeggs/workspaces-effect/PublishabilityDetector`. Since this service
|
|
4399
|
+
* has no dependencies, the layer is constructed with `Layer.succeed` rather than
|
|
4400
|
+
* `Layer.effect`.
|
|
4401
|
+
*
|
|
4402
|
+
* @example Checking publishability of all packages
|
|
4403
|
+
* ```typescript
|
|
4404
|
+
* import { Effect } from "effect";
|
|
4405
|
+
* import { NodeContext } from "@effect/platform-node";
|
|
4406
|
+
* import { PublishabilityDetector, WorkspaceDiscovery, WorkspacesLive } from "workspaces-effect";
|
|
4407
|
+
*
|
|
4408
|
+
* const program = Effect.gen(function* () {
|
|
4409
|
+
* const discovery = yield* WorkspaceDiscovery;
|
|
4410
|
+
* const publishability = yield* PublishabilityDetector;
|
|
4411
|
+
* const packages = yield* discovery.listPackages();
|
|
4412
|
+
*
|
|
4413
|
+
* for (const pkg of packages) {
|
|
4414
|
+
* const targets = yield* publishability.detect(pkg, "/path/to/monorepo");
|
|
4415
|
+
* if (targets.length > 0) {
|
|
4416
|
+
* console.log(`${pkg.name} publishes to:`, targets.map((t) => t.registry));
|
|
4417
|
+
* } else {
|
|
4418
|
+
* console.log(`${pkg.name} is not publishable`);
|
|
4419
|
+
* }
|
|
4420
|
+
* }
|
|
4421
|
+
* });
|
|
4422
|
+
*
|
|
4423
|
+
* Effect.runPromise(
|
|
4424
|
+
* program.pipe(
|
|
4425
|
+
* Effect.provide(WorkspacesLive),
|
|
4426
|
+
* Effect.provide(NodeContext.layer),
|
|
4427
|
+
* )
|
|
4428
|
+
* );
|
|
4429
|
+
* ```
|
|
4430
|
+
*
|
|
4431
|
+
* @public
|
|
4432
|
+
*/
|
|
4433
|
+
declare class PublishabilityDetector extends PublishabilityDetector_base {} //#endregion
|
|
4434
|
+
//#region src/layers/PublishabilityDetectorLive.d.ts
|
|
4435
|
+
/**
|
|
4436
|
+
* Live layer for the {@link PublishabilityDetector} service.
|
|
4437
|
+
*
|
|
4438
|
+
* Determines whether a workspace package is publishable to npm based
|
|
4439
|
+
* on its `private` flag and `publishConfig` settings.
|
|
4440
|
+
*
|
|
4441
|
+
* @remarks
|
|
4442
|
+
* This layer is pure -- it has no dependencies on `FileSystem`, `Path`, or
|
|
4443
|
+
* any other platform services. It uses `Layer.succeed` rather than
|
|
4444
|
+
* `Layer.effect`. Custom layers can override by providing their own
|
|
4445
|
+
* `Layer` for `PublishabilityDetector`.
|
|
4446
|
+
*
|
|
4447
|
+
* @privateRemarks
|
|
4448
|
+
* Builds a single {@link PublishTarget} from `publishConfig` fields,
|
|
4449
|
+
* defaulting to the public npm registry when no registry is specified.
|
|
4450
|
+
*
|
|
4451
|
+
* @example
|
|
4452
|
+
* ```typescript
|
|
4453
|
+
* import { Effect } from "effect";
|
|
4454
|
+
* import { PublishabilityDetector, PublishabilityDetectorLive } from "workspaces-effect";
|
|
4455
|
+
* import { WorkspacePackage } from "workspaces-effect";
|
|
4456
|
+
*
|
|
4457
|
+
* const program = Effect.gen(function* () {
|
|
4458
|
+
* const detector = yield* PublishabilityDetector;
|
|
4459
|
+
* const targets = yield* detector.detect(somePackage, "/path/to/root");
|
|
4460
|
+
* return targets;
|
|
4461
|
+
* });
|
|
4462
|
+
*
|
|
4463
|
+
* Effect.runPromise(
|
|
4464
|
+
* program.pipe(Effect.provide(PublishabilityDetectorLive))
|
|
4465
|
+
* );
|
|
4466
|
+
* ```
|
|
4467
|
+
*
|
|
4468
|
+
* @public
|
|
4029
4469
|
*/
|
|
4030
4470
|
//#endregion
|
|
4031
4471
|
//#region ../silk-effects/dist/dev/pkg/index.d.ts
|
|
@@ -5585,6 +6025,16 @@ declare const DependencyTableTypeSchema: Schema.Literal<["dependency", "devDepen
|
|
|
5585
6025
|
* @public
|
|
5586
6026
|
*/
|
|
5587
6027
|
type DependencyTableType = typeof DependencyTableTypeSchema.Type;
|
|
6028
|
+
/**
|
|
6029
|
+
* The canonical accepted-value pattern for a dependency-table From/To cell:
|
|
6030
|
+
* the em-dash sentinel (U+2014), a bare/`~`/`^` semver, or — as a last-resort
|
|
6031
|
+
* fallback when a `catalog:`/`workspace:` specifier could not be resolved to a
|
|
6032
|
+
* concrete version — a pnpm protocol string. Non-overlapping alternatives keep
|
|
6033
|
+
* this free of polynomial backtracking (CodeQL).
|
|
6034
|
+
*
|
|
6035
|
+
* @public
|
|
6036
|
+
*/
|
|
6037
|
+
declare const VERSION_RE: RegExp;
|
|
5588
6038
|
/**
|
|
5589
6039
|
* Version string or em dash (U+2014) sentinel for added/removed entries.
|
|
5590
6040
|
*
|
|
@@ -5857,7 +6307,7 @@ declare class DependencyTable {
|
|
|
5857
6307
|
/**
|
|
5858
6308
|
* Class-based API wrapper for changeset linting.
|
|
5859
6309
|
*
|
|
5860
|
-
* Provides a static class interface that runs all remark-lint rules
|
|
6310
|
+
* Provides a static class interface that runs all five remark-lint rules
|
|
5861
6311
|
* against changeset markdown files and returns structured diagnostics.
|
|
5862
6312
|
*
|
|
5863
6313
|
* @internal
|
|
@@ -5871,11 +6321,12 @@ declare class DependencyTable {
|
|
|
5871
6321
|
* (file, line, column) for integration with editors, CI reporters, and
|
|
5872
6322
|
* the Effect CLI's `lint` and `check` commands.
|
|
5873
6323
|
*
|
|
5874
|
-
* The
|
|
6324
|
+
* The five rules that produce lint messages are:
|
|
5875
6325
|
*
|
|
5876
6326
|
* - **heading-hierarchy** -- ensures headings follow a valid nesting order
|
|
5877
6327
|
* - **required-sections** -- checks that mandatory sections are present
|
|
5878
6328
|
* - **content-structure** -- validates the structure of section content
|
|
6329
|
+
* - **dependency-table-format** -- enforces the machine-generated dependency-table format for `## Dependencies` sections
|
|
5879
6330
|
* - **uncategorized-content** -- flags content outside recognized section headings
|
|
5880
6331
|
*
|
|
5881
6332
|
* @public
|
|
@@ -5894,9 +6345,10 @@ interface LintMessage {
|
|
|
5894
6345
|
* Identifier of the remark-lint rule that produced this message.
|
|
5895
6346
|
*
|
|
5896
6347
|
* @remarks
|
|
5897
|
-
* Corresponds to one of the
|
|
5898
|
-
* `"required-sections"`, `"content-structure"`,
|
|
5899
|
-
* Falls back to `"unknown"` if the underlying
|
|
6348
|
+
* Corresponds to one of the five built-in rules: `"heading-hierarchy"`,
|
|
6349
|
+
* `"required-sections"`, `"content-structure"`, `"dependency-table-format"`,
|
|
6350
|
+
* or `"uncategorized-content"`. Falls back to `"unknown"` if the underlying
|
|
6351
|
+
* vfile message has no rule ID.
|
|
5900
6352
|
*/
|
|
5901
6353
|
rule: string;
|
|
5902
6354
|
/**
|
|
@@ -5929,9 +6381,9 @@ interface LintMessage {
|
|
|
5929
6381
|
/**
|
|
5930
6382
|
* Static class for linting changeset markdown files.
|
|
5931
6383
|
*
|
|
5932
|
-
* Runs the
|
|
5933
|
-
* content-structure, uncategorized-content) against
|
|
5934
|
-
* and returns structured {@link LintMessage} diagnostics.
|
|
6384
|
+
* Runs the five remark-lint rules (heading-hierarchy, required-sections,
|
|
6385
|
+
* content-structure, dependency-table-format, uncategorized-content) against
|
|
6386
|
+
* changeset markdown and returns structured {@link LintMessage} diagnostics.
|
|
5935
6387
|
*
|
|
5936
6388
|
* @remarks
|
|
5937
6389
|
* This class implements the pre-validation layer of the three-layer
|
|
@@ -6016,7 +6468,7 @@ declare class ChangesetLinter {
|
|
|
6016
6468
|
*
|
|
6017
6469
|
* @remarks
|
|
6018
6470
|
* Reads the file synchronously, strips YAML frontmatter, and runs all
|
|
6019
|
-
*
|
|
6471
|
+
* five lint rules. The file path is preserved in each returned
|
|
6020
6472
|
* {@link LintMessage} for error reporting.
|
|
6021
6473
|
*
|
|
6022
6474
|
* @param filePath - Absolute or relative path to the changeset `.md` file
|
|
@@ -6027,7 +6479,7 @@ declare class ChangesetLinter {
|
|
|
6027
6479
|
* Validate a markdown string directly.
|
|
6028
6480
|
*
|
|
6029
6481
|
* @remarks
|
|
6030
|
-
* Strips YAML frontmatter (if present) and runs all
|
|
6482
|
+
* Strips YAML frontmatter (if present) and runs all five lint rules
|
|
6031
6483
|
* against the remaining content. This method is useful for validating
|
|
6032
6484
|
* changeset content that is already in memory, such as in test suites
|
|
6033
6485
|
* or editor integrations.
|
|
@@ -6503,6 +6955,53 @@ declare class GitError extends GitErrorBase<{
|
|
|
6503
6955
|
}> {
|
|
6504
6956
|
get message(): string;
|
|
6505
6957
|
}
|
|
6958
|
+
/**
|
|
6959
|
+
* Base class for {@link ChangesetIOError}.
|
|
6960
|
+
*
|
|
6961
|
+
* @privateRemarks
|
|
6962
|
+
* Effect's `Data.TaggedError` creates an anonymous base class that
|
|
6963
|
+
* api-extractor cannot follow without an explicit export.
|
|
6964
|
+
*
|
|
6965
|
+
* @internal
|
|
6966
|
+
*/
|
|
6967
|
+
declare const ChangesetIOErrorBase: new <A extends Record<string, any> = {}>(args: import("effect/Types").VoidIfEmpty<{ readonly [P in keyof A as P extends "_tag" ? never : P]: A[P] }>) => import("effect/Cause").YieldableError & {
|
|
6968
|
+
readonly _tag: "ChangesetIOError";
|
|
6969
|
+
} & Readonly<A>;
|
|
6970
|
+
/**
|
|
6971
|
+
* Changeset file I/O failure.
|
|
6972
|
+
*
|
|
6973
|
+
* @remarks
|
|
6974
|
+
* Raised by {@link DepsRegen} when reading, writing, listing, or deleting
|
|
6975
|
+
* `.changeset/*.md` files fails. Deletion failures during
|
|
6976
|
+
* {@link DepsRegenShape.execute} are tolerated (stale changesets are
|
|
6977
|
+
* skip-and-continue, so an interrupted run stays safely re-runnable);
|
|
6978
|
+
* read, list, and write failures are loud.
|
|
6979
|
+
*
|
|
6980
|
+
* @example
|
|
6981
|
+
* ```typescript
|
|
6982
|
+
* import { Effect } from "effect";
|
|
6983
|
+
* import { ChangesetIOError } from "@savvy-web/changesets";
|
|
6984
|
+
*
|
|
6985
|
+
* declare const program: Effect.Effect<void, ChangesetIOError>;
|
|
6986
|
+
*
|
|
6987
|
+
* const handled = program.pipe(
|
|
6988
|
+
* Effect.catchTag("ChangesetIOError", (err) =>
|
|
6989
|
+
* Effect.logError(`changeset ${err.operation} failed at ${err.path}: ${err.reason}`)
|
|
6990
|
+
* ),
|
|
6991
|
+
* );
|
|
6992
|
+
* ```
|
|
6993
|
+
*
|
|
6994
|
+
* @see {@link DepsRegen} which produces these errors during plan/execute
|
|
6995
|
+
*
|
|
6996
|
+
* @public
|
|
6997
|
+
*/
|
|
6998
|
+
declare class ChangesetIOError extends ChangesetIOErrorBase<{
|
|
6999
|
+
/** Absolute path of the file or directory the operation targeted. */readonly path: string; /** The failed operation. */
|
|
7000
|
+
readonly operation: "read" | "write" | "delete" | "list"; /** Human-readable failure reason. */
|
|
7001
|
+
readonly reason: string;
|
|
7002
|
+
}> {
|
|
7003
|
+
get message(): string;
|
|
7004
|
+
}
|
|
6506
7005
|
/**
|
|
6507
7006
|
* Base class for {@link ReleasePlanError}.
|
|
6508
7007
|
*
|
|
@@ -7453,6 +7952,243 @@ declare const ChangelogServiceBase: Context.TagClass<ChangelogService, "Changelo
|
|
|
7453
7952
|
* @public
|
|
7454
7953
|
*/
|
|
7455
7954
|
declare class ChangelogService extends ChangelogServiceBase {} //#endregion
|
|
7955
|
+
//#region src/services/ChangesetConfig.d.ts
|
|
7956
|
+
/**
|
|
7957
|
+
* Changeset operating mode for a workspace root.
|
|
7958
|
+
* @public
|
|
7959
|
+
*/
|
|
7960
|
+
type ChangesetMode = "silk" | "vanilla" | "none";
|
|
7961
|
+
declare const ChangesetConfig_base: Context.TagClass<ChangesetConfig, "@savvy-web/silk-effects/ChangesetConfig", {
|
|
7962
|
+
readonly mode: (root: string) => Effect.Effect<ChangesetMode>;
|
|
7963
|
+
readonly versionPrivate: (root: string) => Effect.Effect<boolean>;
|
|
7964
|
+
readonly ignorePatterns: (root: string) => Effect.Effect<ReadonlyArray<string>>;
|
|
7965
|
+
readonly isIgnored: (name: string, root: string) => Effect.Effect<boolean>;
|
|
7966
|
+
readonly fixed: (root: string) => Effect.Effect<ReadonlyArray<ReadonlyArray<string>>>;
|
|
7967
|
+
}>;
|
|
7968
|
+
/**
|
|
7969
|
+
* Accessor service over a workspace root's `.changeset/config.json`.
|
|
7970
|
+
*
|
|
7971
|
+
* @remarks
|
|
7972
|
+
* Reads through {@link ChangesetConfigReader} (FileSystem-based) with a per-root cache.
|
|
7973
|
+
* Every accessor is total (error channel `never`): a missing or unreadable config collapses
|
|
7974
|
+
* to `mode: "none"` and empty/false defaults.
|
|
7975
|
+
*
|
|
7976
|
+
* @since 0.4.0
|
|
7977
|
+
* @public
|
|
7978
|
+
*/
|
|
7979
|
+
declare class ChangesetConfig extends ChangesetConfig_base {
|
|
7980
|
+
/**
|
|
7981
|
+
* The one ignore matcher: exact name match, or `@scope/*` wildcard.
|
|
7982
|
+
*
|
|
7983
|
+
* `"@scope/*"` matches `"@scope/anything"` (prefix kept includes the trailing slash),
|
|
7984
|
+
* but not the bare scope `"@scope"`.
|
|
7985
|
+
*/
|
|
7986
|
+
static matches(name: string, pattern: string): boolean;
|
|
7987
|
+
}
|
|
7988
|
+
/**
|
|
7989
|
+
* Live {@link ChangesetConfig} reading via {@link ChangesetConfigReader}, cached per root.
|
|
7990
|
+
*
|
|
7991
|
+
* @remarks
|
|
7992
|
+
* Requires `ChangesetConfigReader` (which requires `FileSystem`). Provide
|
|
7993
|
+
* `ChangesetConfigReaderLive` + a platform layer (`NodeContext.layer`).
|
|
7994
|
+
*
|
|
7995
|
+
* @since 0.4.0
|
|
7996
|
+
* @public
|
|
7997
|
+
*/
|
|
7998
|
+
//#endregion
|
|
7999
|
+
//#region src/changesets/utils/dep-diff.d.ts
|
|
8000
|
+
/**
|
|
8001
|
+
* A workspace package's worth of dependency-table rows.
|
|
8002
|
+
*
|
|
8003
|
+
* @public
|
|
8004
|
+
*/
|
|
8005
|
+
interface WorkspaceDependencyDiff {
|
|
8006
|
+
/** The workspace package whose `package.json` changed. */
|
|
8007
|
+
readonly package: string;
|
|
8008
|
+
/** Repo-relative path of the package directory (taken from the `after` snapshot). */
|
|
8009
|
+
readonly relativePath: string;
|
|
8010
|
+
/** One row per dependency change, sorted by the existing `sortDependencyRows` convention. */
|
|
8011
|
+
readonly rows: ReadonlyArray<DependencyTableRow>;
|
|
8012
|
+
}
|
|
8013
|
+
/**
|
|
8014
|
+
* Diff two workspace snapshots and return per-package dependency-table rows,
|
|
8015
|
+
* comparing already-resolved specifier values per side.
|
|
8016
|
+
*
|
|
8017
|
+
* @param before - Snapshot at the older ref (typically the merge base). A
|
|
8018
|
+
* workspace package absent here reports every declared dep as `"added"`.
|
|
8019
|
+
* @param after - Snapshot at the newer ref (typically the working tree).
|
|
8020
|
+
* @returns One {@link WorkspaceDependencyDiff} entry per workspace package
|
|
8021
|
+
* that has at least one row. Packages with no resolved-value changes are
|
|
8022
|
+
* omitted.
|
|
8023
|
+
*
|
|
8024
|
+
* @public
|
|
8025
|
+
*/
|
|
8026
|
+
declare function computeWorkspaceDependencyDiffs(before: WorkspaceStateSnapshot, after: WorkspaceStateSnapshot): ReadonlyArray<WorkspaceDependencyDiff>; //#endregion
|
|
8027
|
+
//#region src/changesets/services/deps-regen.d.ts
|
|
8028
|
+
/**
|
|
8029
|
+
* Strict detection of "pure dependency changesets" per the documented
|
|
8030
|
+
* rules: single-package frontmatter, single `## Dependencies` heading,
|
|
8031
|
+
* no other body content beyond that section.
|
|
8032
|
+
*
|
|
8033
|
+
* @param content - Raw `.changeset/*.md` file contents.
|
|
8034
|
+
* @returns `{ isPure, package }` — `isPure` is `true` only for a
|
|
8035
|
+
* single-package, Dependencies-only changeset; `package` is the sole
|
|
8036
|
+
* frontmatter package name (or `null` when not pure).
|
|
8037
|
+
*
|
|
8038
|
+
* @public
|
|
8039
|
+
*/
|
|
8040
|
+
declare function isPureDependencyChangeset(content: string): {
|
|
8041
|
+
isPure: boolean;
|
|
8042
|
+
package: string | null;
|
|
8043
|
+
};
|
|
8044
|
+
/**
|
|
8045
|
+
* A complete, side-effect-free regen plan: which stale pure-dependency
|
|
8046
|
+
* changesets to delete, which fresh changesets to write (carrying the
|
|
8047
|
+
* already-resolved diff), and which mixed changesets were left untouched.
|
|
8048
|
+
*
|
|
8049
|
+
* @public
|
|
8050
|
+
*/
|
|
8051
|
+
interface RegenPlan {
|
|
8052
|
+
readonly toDelete: ReadonlyArray<{
|
|
8053
|
+
readonly file: string;
|
|
8054
|
+
readonly package: string;
|
|
8055
|
+
}>;
|
|
8056
|
+
readonly toWrite: ReadonlyArray<{
|
|
8057
|
+
readonly file: string;
|
|
8058
|
+
readonly package: string;
|
|
8059
|
+
readonly diff: WorkspaceDependencyDiff;
|
|
8060
|
+
}>;
|
|
8061
|
+
readonly skippedMixed: ReadonlyArray<string>;
|
|
8062
|
+
}
|
|
8063
|
+
/**
|
|
8064
|
+
* The result of applying a {@link RegenPlan}: the files actually deleted
|
|
8065
|
+
* and written, plus the mixed changesets that were skipped.
|
|
8066
|
+
*
|
|
8067
|
+
* @public
|
|
8068
|
+
*/
|
|
8069
|
+
interface RegenResult {
|
|
8070
|
+
readonly deleted: ReadonlyArray<string>;
|
|
8071
|
+
readonly written: ReadonlyArray<string>;
|
|
8072
|
+
readonly skippedMixed: ReadonlyArray<string>;
|
|
8073
|
+
}
|
|
8074
|
+
/**
|
|
8075
|
+
* Options for {@link DepsRegenShape.plan}.
|
|
8076
|
+
*
|
|
8077
|
+
* @public
|
|
8078
|
+
*/
|
|
8079
|
+
interface DepsRegenOptions {
|
|
8080
|
+
/** Project root (containing `.changeset/`). */
|
|
8081
|
+
readonly cwd: string;
|
|
8082
|
+
/** Override the base branch used to compute the merge-base when `from` is omitted. */
|
|
8083
|
+
readonly base?: string;
|
|
8084
|
+
/** Restrict regeneration to a single workspace package. */
|
|
8085
|
+
readonly package?: string;
|
|
8086
|
+
/**
|
|
8087
|
+
* When `true`, retain `devDependency` rows (the `deps detect` path);
|
|
8088
|
+
* when falsy (the `deps regen` default), drop them unconditionally.
|
|
8089
|
+
* Protocol resolution runs regardless.
|
|
8090
|
+
*/
|
|
8091
|
+
readonly includeDevDeps?: boolean;
|
|
8092
|
+
/**
|
|
8093
|
+
* Older ref to diff from. Defaults to `git merge-base <base branch> HEAD`.
|
|
8094
|
+
*/
|
|
8095
|
+
readonly from?: string;
|
|
8096
|
+
/**
|
|
8097
|
+
* Newer ref to diff to. Defaults to the working tree (staged + unstaged
|
|
8098
|
+
* + untracked) via `PointInTimeWorkspace.worktree`.
|
|
8099
|
+
*/
|
|
8100
|
+
readonly to?: string;
|
|
8101
|
+
}
|
|
8102
|
+
/**
|
|
8103
|
+
* Effect service interface for the deps regen/detect orchestration.
|
|
8104
|
+
*
|
|
8105
|
+
* @public
|
|
8106
|
+
*/
|
|
8107
|
+
interface DepsRegenShape {
|
|
8108
|
+
/**
|
|
8109
|
+
* Compute a complete {@link RegenPlan}. Read-only against the filesystem:
|
|
8110
|
+
* only inspects the existing `.changeset/*.md` files to detect
|
|
8111
|
+
* stale/mixed changesets.
|
|
8112
|
+
*
|
|
8113
|
+
* @param options - See {@link DepsRegenOptions}.
|
|
8114
|
+
* @returns An Effect yielding the plan, or failing with {@link GitError},
|
|
8115
|
+
* `WorkspaceDiscoveryError`, {@link ChangesetIOError} (an unreadable
|
|
8116
|
+
* `.changeset` directory or a genuinely unreadable changeset file list),
|
|
8117
|
+
* or `PointInTimeReadError` (a snapshot read failed for either ref).
|
|
8118
|
+
*/
|
|
8119
|
+
readonly plan: (options: DepsRegenOptions) => Effect.Effect<RegenPlan, GitError | WorkspaceDiscoveryError | ChangesetIOError | PointInTimeReadError, never>;
|
|
8120
|
+
/**
|
|
8121
|
+
* Apply a {@link RegenPlan}: write fresh changesets first, then delete
|
|
8122
|
+
* stale ones. Writes fail loudly with {@link ChangesetIOError}; deletion
|
|
8123
|
+
* failures are tolerated (skip-and-continue) so an interrupted run stays
|
|
8124
|
+
* safely re-runnable.
|
|
8125
|
+
*
|
|
8126
|
+
* @param plan - The plan produced by {@link DepsRegenShape.plan}.
|
|
8127
|
+
* @returns An Effect yielding a {@link RegenResult}.
|
|
8128
|
+
*/
|
|
8129
|
+
readonly execute: (plan: RegenPlan) => Effect.Effect<RegenResult, ChangesetIOError, never>;
|
|
8130
|
+
}
|
|
8131
|
+
/**
|
|
8132
|
+
* @internal
|
|
8133
|
+
*/
|
|
8134
|
+
declare const DepsRegenBase: Context.TagClass<DepsRegen, "Changesets/DepsRegen", DepsRegenShape>;
|
|
8135
|
+
/**
|
|
8136
|
+
* Effect service tag for {@link DepsRegenShape}.
|
|
8137
|
+
*
|
|
8138
|
+
* @example
|
|
8139
|
+
* ```typescript
|
|
8140
|
+
* import { Effect } from "effect";
|
|
8141
|
+
* import { Changesets } from "@savvy-web/silk-effects";
|
|
8142
|
+
*
|
|
8143
|
+
* const program = Effect.gen(function* () {
|
|
8144
|
+
* const svc = yield* Changesets.DepsRegen;
|
|
8145
|
+
* const plan = yield* svc.plan({ cwd: process.cwd() });
|
|
8146
|
+
* return yield* svc.execute(plan);
|
|
8147
|
+
* });
|
|
8148
|
+
* ```
|
|
8149
|
+
*
|
|
8150
|
+
* @public
|
|
8151
|
+
*/
|
|
8152
|
+
declare class DepsRegen extends DepsRegenBase {}
|
|
8153
|
+
/**
|
|
8154
|
+
* Live layer for {@link DepsRegen}.
|
|
8155
|
+
*
|
|
8156
|
+
* Requires `PointInTimeWorkspace`, `WorkspaceDiscovery`,
|
|
8157
|
+
* `PublishabilityDetector` (all from `workspaces-effect`),
|
|
8158
|
+
* {@link ConfigInspector}, {@link ChangesetConfig}, and
|
|
8159
|
+
* `FileSystem.FileSystem` (resolved once at construction and closed over by
|
|
8160
|
+
* the shape, keeping `plan`/`execute` themselves requirement-free).
|
|
8161
|
+
*
|
|
8162
|
+
* @public
|
|
8163
|
+
*/
|
|
8164
|
+
declare const DepsRegenLive: Layer.Layer<DepsRegen, never, PointInTimeWorkspace | ConfigInspector | WorkspaceDiscovery | PublishabilityDetector | ChangesetConfig | FileSystem.FileSystem>;
|
|
8165
|
+
/**
|
|
8166
|
+
* Batteries-included {@link DepsRegen} layer: silk's opinionated default
|
|
8167
|
+
* composition of the full dependency graph. Only the platform services
|
|
8168
|
+
* remain — note that {@link PointInTimeWorkspace} reads git history, so
|
|
8169
|
+
* this layer genuinely requires `CommandExecutor` in addition to
|
|
8170
|
+
* `FileSystem`/`Path`: provide a git-capable platform layer
|
|
8171
|
+
* (`NodeContext.layer`), not a bare filesystem-only layer.
|
|
8172
|
+
*
|
|
8173
|
+
* Gating uses silk's adaptive publishability detector
|
|
8174
|
+
* ({@link PublishabilityDetectorAdaptiveLive}), so the default semantics
|
|
8175
|
+
* are "versionable minus ignored" — identical to the savvy CLI and MCP
|
|
8176
|
+
* runtimes. Consumers who need to swap any dependency (test detectors,
|
|
8177
|
+
* alternate config sources) should keep composing {@link DepsRegenLive}
|
|
8178
|
+
* directly; this layer is purely additive.
|
|
8179
|
+
*
|
|
8180
|
+
* @example
|
|
8181
|
+
* ```typescript
|
|
8182
|
+
* import { NodeContext } from "@effect/platform-node";
|
|
8183
|
+
* import { Layer } from "effect";
|
|
8184
|
+
* import { Changesets } from "@savvy-web/silk-effects";
|
|
8185
|
+
*
|
|
8186
|
+
* const depsRegen = Changesets.DepsRegenDefault.pipe(Layer.provide(NodeContext.layer));
|
|
8187
|
+
* ```
|
|
8188
|
+
*
|
|
8189
|
+
* @public
|
|
8190
|
+
*/
|
|
8191
|
+
declare const DepsRegenDefault: Layer.Layer<DepsRegen, never, FileSystem.FileSystem | Path.Path | CommandExecutor.CommandExecutor>; //#endregion
|
|
7456
8192
|
//#region src/changesets/schemas/release-plan.d.ts
|
|
7457
8193
|
/** A semantic-version bump level (the `"none"` plan type is filtered out upstream). @public */
|
|
7458
8194
|
declare const BumpTypeSchema: Schema.Literal<["major", "minor", "patch"]>;
|
|
@@ -7552,8 +8288,8 @@ interface ReleasePlannerShape {
|
|
|
7552
8288
|
declare const ReleasePlannerBase: Context.TagClass<ReleasePlanner, "ReleasePlanner", ReleasePlannerShape>;
|
|
7553
8289
|
/** Effect service tag for the release planner. @public */
|
|
7554
8290
|
declare class ReleasePlanner extends ReleasePlannerBase {}
|
|
7555
|
-
/** Production layer. Requires {@link ConfigInspector} (used by `apply`)
|
|
7556
|
-
declare const ReleasePlannerLive: Layer.Layer<ReleasePlanner, never, ConfigInspector>;
|
|
8291
|
+
/** Production layer. Requires {@link ConfigInspector} (used by `apply`) and `FileSystem`. @public */
|
|
8292
|
+
declare const ReleasePlannerLive: Layer.Layer<ReleasePlanner, never, ConfigInspector | FileSystem.FileSystem>;
|
|
7557
8293
|
/**
|
|
7558
8294
|
* Test factory — supply fixed results for any subset of methods. Unsupplied
|
|
7559
8295
|
* methods fail with a `ReleasePlanError`.
|
|
@@ -7565,60 +8301,6 @@ declare function makeReleasePlannerTest(fixed: {
|
|
|
7565
8301
|
readonly preview?: ChangesetPreview;
|
|
7566
8302
|
readonly apply?: AppliedRelease;
|
|
7567
8303
|
}): Layer.Layer<ReleasePlanner>; //#endregion
|
|
7568
|
-
//#region src/changesets/services/workspace-snapshot.d.ts
|
|
7569
|
-
/**
|
|
7570
|
-
* One workspace package as it existed at a specific git ref.
|
|
7571
|
-
*
|
|
7572
|
-
* @public
|
|
7573
|
-
*/
|
|
7574
|
-
interface WorkspaceSnapshot {
|
|
7575
|
-
/** Package name from `package.json#name`. */
|
|
7576
|
-
readonly name: string;
|
|
7577
|
-
/** Repo-relative path of the package directory at this ref. */
|
|
7578
|
-
readonly relativePath: string;
|
|
7579
|
-
/** Package version from `package.json#version`. */
|
|
7580
|
-
readonly version: string;
|
|
7581
|
-
/** Declared `dependencies` (raw strings, including `workspace:` / `catalog:` protocols). */
|
|
7582
|
-
readonly dependencies: Readonly<Record<string, string>>;
|
|
7583
|
-
/** Declared `devDependencies`. */
|
|
7584
|
-
readonly devDependencies: Readonly<Record<string, string>>;
|
|
7585
|
-
/** Declared `peerDependencies`. */
|
|
7586
|
-
readonly peerDependencies: Readonly<Record<string, string>>;
|
|
7587
|
-
/** Declared `optionalDependencies`. */
|
|
7588
|
-
readonly optionalDependencies: Readonly<Record<string, string>>;
|
|
7589
|
-
}
|
|
7590
|
-
/**
|
|
7591
|
-
* Effect service interface for reading workspace snapshots.
|
|
7592
|
-
*
|
|
7593
|
-
* @public
|
|
7594
|
-
*/
|
|
7595
|
-
interface WorkspaceSnapshotReaderShape {
|
|
7596
|
-
/**
|
|
7597
|
-
* Read every workspace package's snapshot at the given git ref.
|
|
7598
|
-
*
|
|
7599
|
-
* @param cwd - Project root (must be inside a git repo)
|
|
7600
|
-
* @param ref - Any valid git revision spec — branch, tag, SHA, `HEAD~1`, etc.
|
|
7601
|
-
* @returns Effect resolving to one {@link WorkspaceSnapshot} per workspace
|
|
7602
|
-
* package present at that ref, or failing with {@link GitError}
|
|
7603
|
-
*/
|
|
7604
|
-
readonly snapshotAt: (cwd: string, ref: string) => Effect.Effect<ReadonlyArray<WorkspaceSnapshot>, GitError>;
|
|
7605
|
-
}
|
|
7606
|
-
/**
|
|
7607
|
-
* @internal
|
|
7608
|
-
*/
|
|
7609
|
-
declare const WorkspaceSnapshotReaderBase: Context.TagClass<WorkspaceSnapshotReader, "WorkspaceSnapshotReader", WorkspaceSnapshotReaderShape>;
|
|
7610
|
-
/**
|
|
7611
|
-
* Effect service tag for {@link WorkspaceSnapshotReaderShape}.
|
|
7612
|
-
*
|
|
7613
|
-
* @public
|
|
7614
|
-
*/
|
|
7615
|
-
declare class WorkspaceSnapshotReader extends WorkspaceSnapshotReaderBase {}
|
|
7616
|
-
/**
|
|
7617
|
-
* Production layer for {@link WorkspaceSnapshotReader}.
|
|
7618
|
-
*
|
|
7619
|
-
* @public
|
|
7620
|
-
*/
|
|
7621
|
-
declare const WorkspaceSnapshotReaderLive: Layer.Layer<WorkspaceSnapshotReader>; //#endregion
|
|
7622
8304
|
//#region src/changesets/schemas/changeset.d.ts
|
|
7623
8305
|
/**
|
|
7624
8306
|
* Schema for a changeset summary (1--1000 characters).
|
|
@@ -8254,33 +8936,6 @@ declare const LegacyVersionFilesSchema: Schema.Array$<Schema.Struct<{
|
|
|
8254
8936
|
paths: Schema.optional<Schema.Array$<Schema.filter<typeof Schema.String>>>; /** Workspace package name to source the version from, bypassing path-based resolution. */
|
|
8255
8937
|
package: Schema.optional<Schema.filter<typeof Schema.String>>;
|
|
8256
8938
|
}>>; //#endregion
|
|
8257
|
-
//#region src/changesets/utils/dep-diff.d.ts
|
|
8258
|
-
/**
|
|
8259
|
-
* A workspace package's worth of dependency-table rows.
|
|
8260
|
-
*
|
|
8261
|
-
* @public
|
|
8262
|
-
*/
|
|
8263
|
-
interface WorkspaceDependencyDiff {
|
|
8264
|
-
/** The workspace package whose `package.json` changed. */
|
|
8265
|
-
readonly package: string;
|
|
8266
|
-
/** Repo-relative path of the package directory (taken from the `after` snapshot when available). */
|
|
8267
|
-
readonly relativePath: string;
|
|
8268
|
-
/** One row per dependency change, sorted by the existing `sortDependencyRows` convention. */
|
|
8269
|
-
readonly rows: ReadonlyArray<DependencyTableRow>;
|
|
8270
|
-
}
|
|
8271
|
-
/**
|
|
8272
|
-
* Diff two workspace snapshots and return per-package dependency-table rows.
|
|
8273
|
-
*
|
|
8274
|
-
* @param before - Snapshot at the older ref (typically the merge base). Pass
|
|
8275
|
-
* `null` for workspace packages that did not exist at the older ref — every
|
|
8276
|
-
* declared dep is then reported as `"added"`.
|
|
8277
|
-
* @param after - Snapshot at the newer ref (typically the working tree).
|
|
8278
|
-
* @returns One {@link WorkspaceDependencyDiff} entry per workspace package
|
|
8279
|
-
* that has at least one row. Packages with no changes are omitted.
|
|
8280
|
-
*
|
|
8281
|
-
* @public
|
|
8282
|
-
*/
|
|
8283
|
-
declare function computeWorkspaceDependencyDiffs(beforeSnapshots: ReadonlyArray<WorkspaceSnapshot>, afterSnapshots: ReadonlyArray<WorkspaceSnapshot>): ReadonlyArray<WorkspaceDependencyDiff>; //#endregion
|
|
8284
8939
|
//#region src/changesets/utils/dependency-table.d.ts
|
|
8285
8940
|
/**
|
|
8286
8941
|
* Serialize dependency table rows to a markdown table string.
|
|
@@ -8308,6 +8963,14 @@ declare function computeWorkspaceDependencyDiffs(beforeSnapshots: ReadonlyArray<
|
|
|
8308
8963
|
* @internal
|
|
8309
8964
|
*/
|
|
8310
8965
|
declare function serializeDependencyTableToMarkdown(rows: DependencyTableRow[]): string; //#endregion
|
|
8966
|
+
//#region src/changesets/utils/git.d.ts
|
|
8967
|
+
/**
|
|
8968
|
+
* Run `git merge-base <base> HEAD`, returning the SHA. Errors propagate
|
|
8969
|
+
* as {@link GitError}.
|
|
8970
|
+
*
|
|
8971
|
+
* @internal
|
|
8972
|
+
*/
|
|
8973
|
+
declare function gitMergeBase(cwd: string, base: string): Effect.Effect<string, GitError>; //#endregion
|
|
8311
8974
|
//#region src/changesets/utils/publishability.d.ts
|
|
8312
8975
|
/**
|
|
8313
8976
|
* Compute the set of currently-publishable workspace package names.
|
|
@@ -8316,12 +8979,24 @@ declare function serializeDependencyTableToMarkdown(rows: DependencyTableRow[]):
|
|
|
8316
8979
|
* Uses the currently-active {@link SilkPublishability} — wire the
|
|
8317
8980
|
* {@link SilkPublishabilityDetectorLive} layer to get silk semantics.
|
|
8318
8981
|
*
|
|
8982
|
+
* `root` is passed through verbatim to `detector.detect(pkg, root)` for every
|
|
8983
|
+
* package — it must be the project root (the directory containing
|
|
8984
|
+
* `.changeset/`), NOT the individual package's directory. The vanilla
|
|
8985
|
+
* `PublishabilityDetectorLive` and plain `SilkPublishabilityDetectorLive`
|
|
8986
|
+
* both ignore this argument, but the ignore/mode-aware
|
|
8987
|
+
* `PublishabilityDetectorAdaptiveLive` reads `.changeset/config.json`
|
|
8988
|
+
* relative to it, so passing a package subdirectory silently makes every
|
|
8989
|
+
* package resolve to "not publishable". Mirrors
|
|
8990
|
+
* {@link SilkPublishability.listPublishable}, which takes the same
|
|
8991
|
+
* single-root parameter for the same reason.
|
|
8992
|
+
*
|
|
8319
8993
|
* @param packages - The workspace packages to evaluate
|
|
8994
|
+
* @param root - Absolute path to the project root containing `.changeset/`
|
|
8320
8995
|
* @returns An Effect yielding a `Set` of publishable package names
|
|
8321
8996
|
*
|
|
8322
8997
|
* @public
|
|
8323
8998
|
*/
|
|
8324
|
-
declare function listPublishablePackageNames(packages: ReadonlyArray<WorkspacePackage
|
|
8999
|
+
declare function listPublishablePackageNames(packages: ReadonlyArray<WorkspacePackage>, root: string): Effect.Effect<ReadonlySet<string>, never, PublishabilityDetector>; //#endregion
|
|
8325
9000
|
//#region src/changesets/utils/version-files.d.ts
|
|
8326
9001
|
/**
|
|
8327
9002
|
* Result of a single version file update.
|
|
@@ -8526,27 +9201,6 @@ declare class VersionFiles {
|
|
|
8526
9201
|
*/
|
|
8527
9202
|
static processResolvedVersionFiles(scopes: ReadonlyArray<ResolvedPackageScope>, dryRun?: boolean): VersionFileUpdate[];
|
|
8528
9203
|
} //#endregion
|
|
8529
|
-
//#region src/changesets/utils/worktree-snapshot.d.ts
|
|
8530
|
-
/**
|
|
8531
|
-
* Run `git merge-base <base> HEAD`, returning the SHA. Errors propagate
|
|
8532
|
-
* as {@link GitError}.
|
|
8533
|
-
*
|
|
8534
|
-
* @internal
|
|
8535
|
-
*/
|
|
8536
|
-
declare function gitMergeBase(cwd: string, base: string): Effect.Effect<string, GitError>;
|
|
8537
|
-
/**
|
|
8538
|
-
* Read every workspace package's `package.json` from the live working
|
|
8539
|
-
* tree, returning {@link WorkspaceSnapshot} entries matching the shape
|
|
8540
|
-
* `WorkspaceSnapshotReader.snapshotAt` produces for git refs.
|
|
8541
|
-
*
|
|
8542
|
-
* @remarks
|
|
8543
|
-
* Falls back to root-only when `pnpm-workspace.yaml` is missing or
|
|
8544
|
-
* unparseable. Uses `node:fs.readdirSync` for directory expansion
|
|
8545
|
-
* (portable across platforms — `execFileSync("ls")` is not).
|
|
8546
|
-
*
|
|
8547
|
-
* @internal
|
|
8548
|
-
*/
|
|
8549
|
-
declare function snapshotFromWorktree(cwd: string): ReadonlyArray<WorkspaceSnapshot>; //#endregion
|
|
8550
9204
|
//#region ../../node_modules/.pnpm/micromark-util-types@2.0.2/node_modules/micromark-util-types/index.d.ts
|
|
8551
9205
|
/**
|
|
8552
9206
|
* Enum of allowed token types.
|
|
@@ -9199,7 +9853,7 @@ declare const RequiredSectionsRule$2: Plugin<Root, unknown>; //#endregion
|
|
|
9199
9853
|
//#region src/changesets/remark/rules/uncategorized-content.d.ts
|
|
9200
9854
|
declare const UncategorizedContentRule$2: Plugin<Root, unknown>;
|
|
9201
9855
|
declare namespace index_d_exports {
|
|
9202
|
-
export { AggregateDependencyTablesPlugin, AppliedRelease, AppliedReleaseEntrySchema, AppliedReleaseSchema, BranchAnalysis, BranchAnalysisSchema, BranchAnalyzer, BranchAnalyzerBase, BranchAnalyzerLive, BranchAnalyzerShape, BranchFileEntry, BranchFileEntrySchema, BumpType, BumpTypeSchema, Categories, Changelog, ChangelogService, ChangelogServiceBase, ChangelogServiceShape, ChangelogTransformer, Changeset, ChangesetLinter, ChangesetOptions, ChangesetOptionsSchema, ChangesetPreview, ChangesetPreviewSchema, ChangesetSchema, ChangesetSummarySchema, ChangesetValidationError, ChangesetValidationErrorBase, Classification, ClassificationReason, ClassificationReasonSchema, ClassificationSchema, CommitHashSchema, ConfigInspector, ConfigInspectorBase, ConfigInspectorLive, ConfigInspectorShape, ConfigurationError, ConfigurationErrorBase, ContentStructureRule$2 as ContentStructureRule, ContributorFootnotesPlugin, DeduplicateItemsPlugin, DependencyAction, DependencyActionSchema, DependencyTable, DependencyTableFormatRule$2 as DependencyTableFormatRule, DependencyTableRow, DependencyTableRowSchema, DependencyTableSchema, DependencyTableType, DependencyTableTypeSchema, DependencyType, DependencyTypeSchema, DependencyUpdate, DependencyUpdateSchema, FileStatus, FileStatusSchema, GitError, GitErrorBase, GitHubApiError, GitHubApiErrorBase, GitHubCommitInfo, GitHubInfo, GitHubInfoSchema, GitHubLive, GitHubService, GitHubServiceBase, GitHubServiceShape, GlobSchema, HeadingHierarchyRule$2 as HeadingHierarchyRule, InspectedConfig, InspectedConfigSchema, IssueLinkRefsPlugin, IssueNumberSchema, JsonPathSchema, LegacyVersionFileConfig, LegacyVersionFileConfigSchema, LegacyVersionFilesSchema, LintMessage, MarkdownLive, MarkdownParseError, MarkdownParseErrorBase, MarkdownService, MarkdownServiceBase, MarkdownServiceShape, ContentStructureRule$1 as MarkdownlintContentStructureRule, DependencyTableFormatRule$1 as MarkdownlintDependencyTableFormatRule, HeadingHierarchyRule$1 as MarkdownlintHeadingHierarchyRule, RequiredSectionsRule$1 as MarkdownlintRequiredSectionsRule, UncategorizedContentRule$1 as MarkdownlintUncategorizedContentRule, MergeSectionsPlugin, NonEmptyString, NormalizeFormatPlugin, PackageScope, PackageScopeSchema, PackagesRecordSchema, PendingChangeset, PendingChangesetSchema, PositiveInteger, PreviewRelease, PreviewReleaseSchema, ReleasePlanError, ReleasePlanErrorBase, ReleasePlanner, ReleasePlannerBase, ReleasePlannerLive, ReleasePlannerShape, ReorderSectionsPlugin, RepoSchema, RequiredSectionsRule$2 as RequiredSectionsRule, ResolvedPackageScope, ResolvedPackageScopeSchema, ResolvedVersionFile, ResolvedVersionFileSchema, SectionCategory, SectionCategorySchema, SilkChangesetPreset, SilkChangesetTransformPreset, SilkChangesetsRules$1 as SilkChangesetsRules, UncategorizedContentRule$2 as UncategorizedContentRule, UrlOrMarkdownLinkSchema, UsernameSchema, VersionFileConfig, VersionFileConfigSchema, VersionFileError, VersionFileErrorBase, VersionFileUpdate, VersionFileUpdateRecordSchema, VersionFiles, VersionFilesSchema, VersionOrEmptySchema, VersionType, VersionTypeSchema, WorkspaceDependencyDiff,
|
|
9856
|
+
export { AggregateDependencyTablesPlugin, AppliedRelease, AppliedReleaseEntrySchema, AppliedReleaseSchema, BranchAnalysis, BranchAnalysisSchema, BranchAnalyzer, BranchAnalyzerBase, BranchAnalyzerLive, BranchAnalyzerShape, BranchFileEntry, BranchFileEntrySchema, BumpType, BumpTypeSchema, Categories, Changelog, ChangelogService, ChangelogServiceBase, ChangelogServiceShape, ChangelogTransformer, Changeset, ChangesetIOError, ChangesetIOErrorBase, ChangesetLinter, ChangesetOptions, ChangesetOptionsSchema, ChangesetPreview, ChangesetPreviewSchema, ChangesetSchema, ChangesetSummarySchema, ChangesetValidationError, ChangesetValidationErrorBase, Classification, ClassificationReason, ClassificationReasonSchema, ClassificationSchema, CommitHashSchema, ConfigInspector, ConfigInspectorBase, ConfigInspectorLive, ConfigInspectorShape, ConfigurationError, ConfigurationErrorBase, ContentStructureRule$2 as ContentStructureRule, ContributorFootnotesPlugin, DeduplicateItemsPlugin, DependencyAction, DependencyActionSchema, DependencyTable, DependencyTableFormatRule$2 as DependencyTableFormatRule, DependencyTableRow, DependencyTableRowSchema, DependencyTableSchema, DependencyTableType, DependencyTableTypeSchema, DependencyType, DependencyTypeSchema, DependencyUpdate, DependencyUpdateSchema, DepsRegen, DepsRegenBase, DepsRegenDefault, DepsRegenLive, DepsRegenOptions, DepsRegenShape, FileStatus, FileStatusSchema, GitError, GitErrorBase, GitHubApiError, GitHubApiErrorBase, GitHubCommitInfo, GitHubInfo, GitHubInfoSchema, GitHubLive, GitHubService, GitHubServiceBase, GitHubServiceShape, GlobSchema, HeadingHierarchyRule$2 as HeadingHierarchyRule, InspectedConfig, InspectedConfigSchema, IssueLinkRefsPlugin, IssueNumberSchema, JsonPathSchema, LegacyVersionFileConfig, LegacyVersionFileConfigSchema, LegacyVersionFilesSchema, LintMessage, MarkdownLive, MarkdownParseError, MarkdownParseErrorBase, MarkdownService, MarkdownServiceBase, MarkdownServiceShape, ContentStructureRule$1 as MarkdownlintContentStructureRule, DependencyTableFormatRule$1 as MarkdownlintDependencyTableFormatRule, HeadingHierarchyRule$1 as MarkdownlintHeadingHierarchyRule, RequiredSectionsRule$1 as MarkdownlintRequiredSectionsRule, UncategorizedContentRule$1 as MarkdownlintUncategorizedContentRule, MergeSectionsPlugin, NonEmptyString, NormalizeFormatPlugin, PackageScope, PackageScopeSchema, PackagesRecordSchema, PendingChangeset, PendingChangesetSchema, PositiveInteger, PreviewRelease, PreviewReleaseSchema, RegenPlan, RegenResult, ReleasePlanError, ReleasePlanErrorBase, ReleasePlanner, ReleasePlannerBase, ReleasePlannerLive, ReleasePlannerShape, ReorderSectionsPlugin, RepoSchema, RequiredSectionsRule$2 as RequiredSectionsRule, ResolvedPackageScope, ResolvedPackageScopeSchema, ResolvedVersionFile, ResolvedVersionFileSchema, SectionCategory, SectionCategorySchema, SilkChangesetPreset, SilkChangesetTransformPreset, SilkChangesetsRules$1 as SilkChangesetsRules, UncategorizedContentRule$2 as UncategorizedContentRule, UrlOrMarkdownLinkSchema, UsernameSchema, VERSION_RE, VersionFileConfig, VersionFileConfigSchema, VersionFileError, VersionFileErrorBase, VersionFileUpdate, VersionFileUpdateRecordSchema, VersionFiles, VersionFilesSchema, VersionOrEmptySchema, VersionType, VersionTypeSchema, WorkspaceDependencyDiff, WorkspaceVersion, changelogFunctions, computeWorkspaceDependencyDiffs, gitMergeBase, isPureDependencyChangeset, listPublishablePackageNames, makeBranchAnalyzerTest, makeConfigInspectorTest, makeGitHubTest, makeReleasePlannerTest, serializeDependencyTableToMarkdown };
|
|
9203
9857
|
} //#endregion
|
|
9204
9858
|
//#region src/commitlint/config/schema.d.ts
|
|
9205
9859
|
/**
|