@savvy-web/silk 3.4.1 → 3.5.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -3298,7 +3298,7 @@ type Label = Label$1;
3298
3298
  type Severity = Severity$1;
3299
3299
  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
3300
  //#endregion
3301
- //#region ../../node_modules/.pnpm/@effected+git@0.5.2_effect@4.0.0-beta.101/node_modules/@effected/git/index.d.ts
3301
+ //#region ../../node_modules/.pnpm/@effected+git@0.6.0_effect@4.0.0-beta.101/node_modules/@effected/git/index.d.ts
3302
3302
  //#region src/Git.d.ts
3303
3303
  declare const GitCommandError_base: Schema.Class<GitCommandError, Schema.TaggedStruct<"GitCommandError", {
3304
3304
  /**
@@ -3309,7 +3309,16 @@ declare const GitCommandError_base: Schema.Class<GitCommandError, Schema.TaggedS
3309
3309
  * logic routes on this instead of matching `detail` prose.
3310
3310
  */
3311
3311
  readonly kind: Schema.Literals<readonly ["refused", "failed"]>;
3312
- /** The argument vector, without the leading `git`. */
3312
+ /**
3313
+ * The REDACTED argument vector, without the leading `git`.
3314
+ *
3315
+ * Sensitive positionals — config values, a URL's embedded userinfo — are
3316
+ * already masked by the constructor's redaction mask before this error is
3317
+ * constructed (`configSet`'s value reads `<redacted>`; a
3318
+ * `https://user:token@host/...` remote keeps everything but its
3319
+ * `userinfo@`). The raw argv is never persisted in an error value, and
3320
+ * `message` renders this redacted vector.
3321
+ */
3313
3322
  readonly args: Schema.$Array<Schema.String>;
3314
3323
  /** The working directory the command ran in. */
3315
3324
  readonly cwd: Schema.String;
@@ -3368,6 +3377,70 @@ declare class UnknownRefError extends UnknownRefError_base {
3368
3377
  /** Renders the unresolvable ref into a one-line message. */
3369
3378
  get message(): string;
3370
3379
  }
3380
+ declare const NonFastForwardError_base: Schema.Class<NonFastForwardError, Schema.TaggedStruct<"NonFastForwardError", {
3381
+ /** The working directory the push ran in. */
3382
+ readonly cwd: Schema.String;
3383
+ /** The refspec that was rejected, when the caller passed one. */
3384
+ readonly refspec: Schema.optionalKey<Schema.String>;
3385
+ }>, import("effect/Cause").YieldableError>;
3386
+ /**
3387
+ * A `git push` was rejected because the remote ref has moved: the classic
3388
+ * non-fast-forward rejection (`fetch first` / `non-fast-forward`), or a
3389
+ * `--force-with-lease` lease failure (`stale info`).
3390
+ *
3391
+ * @remarks
3392
+ * The typed signal a fetch-then-retry (or rebase-then-retry) fallback
3393
+ * branches on — every other push failure stays a {@link GitCommandError}.
3394
+ * Only `Git.push` can fail with this error.
3395
+ *
3396
+ * @public
3397
+ */
3398
+ declare class NonFastForwardError extends NonFastForwardError_base {
3399
+ /** Renders the rejected push into a one-line message. */
3400
+ get message(): string;
3401
+ }
3402
+ declare const MergeConflictError_base: Schema.Class<MergeConflictError, Schema.TaggedStruct<"MergeConflictError", {
3403
+ /** The working directory the merge ran in. */
3404
+ readonly cwd: Schema.String;
3405
+ }>, import("effect/Cause").YieldableError>;
3406
+ /**
3407
+ * A merge-shaped operation (`pull`, `stash pop`, `stash apply`) stopped with
3408
+ * conflict markers in the working tree.
3409
+ *
3410
+ * @remarks
3411
+ * The typed signal a resolve-or-abort recovery branches on. The conflicted
3412
+ * state is REAL: git has already written conflict markers, and (for `pull`)
3413
+ * `MERGE_HEAD` is set — the caller owns resolving or aborting. Detection
3414
+ * matches git's conflict report, which lands on STDOUT for a merge and on
3415
+ * stderr for a rebase-mode pull; both streams are inspected.
3416
+ *
3417
+ * @public
3418
+ */
3419
+ declare class MergeConflictError extends MergeConflictError_base {
3420
+ /** Renders the conflicted merge into a one-line message. */
3421
+ get message(): string;
3422
+ }
3423
+ declare const DirtyWorktreeError_base: Schema.Class<DirtyWorktreeError, Schema.TaggedStruct<"DirtyWorktreeError", {
3424
+ /** The working directory whose local changes blocked the operation. */
3425
+ readonly cwd: Schema.String;
3426
+ }>, import("effect/Cause").YieldableError>;
3427
+ /**
3428
+ * A merge-shaped operation refused to start because local modifications would
3429
+ * be overwritten — git's refusal reads
3430
+ * `Your local changes ... would be overwritten by merge`.
3431
+ *
3432
+ * @remarks
3433
+ * The typed "commit or stash first" signal. Unlike {@link MergeConflictError}
3434
+ * the working tree is UNTOUCHED — git aborted before changing anything.
3435
+ * Only the merge-shaped methods (`pull`, `stashPop`, `stashApply`) can fail
3436
+ * with this error.
3437
+ *
3438
+ * @public
3439
+ */
3440
+ declare class DirtyWorktreeError extends DirtyWorktreeError_base {
3441
+ /** Renders the blocked operation into a one-line message. */
3442
+ get message(): string;
3443
+ }
3371
3444
  declare const LsTreeEntry_base: Schema.Class<LsTreeEntry, Schema.Struct<{
3372
3445
  /** The entry's file mode, e.g. `100644`. */
3373
3446
  readonly mode: Schema.String;
@@ -3423,6 +3496,21 @@ declare const CommitInfo_base: Schema.Class<CommitInfo, Schema.Struct<{
3423
3496
  * @public
3424
3497
  */
3425
3498
  declare class CommitInfo extends CommitInfo_base {}
3499
+ /**
3500
+ * Options for {@link StatusEntry.toLine} / {@link StatusEntry.format}: how a
3501
+ * rename/copy entry's path field renders.
3502
+ *
3503
+ * @public
3504
+ */
3505
+ interface StatusRenderOptions {
3506
+ /**
3507
+ * `"new"` (the default) renders only the NEW path — the entry's current
3508
+ * path, the one that exists on disk. `"arrow"` renders git's own non-`-z`
3509
+ * porcelain form, `<origPath> -> <path>`. Non-rename entries are
3510
+ * unaffected either way.
3511
+ */
3512
+ readonly renames?: "new" | "arrow";
3513
+ }
3426
3514
  declare const StatusEntry_base: Schema.Class<StatusEntry, Schema.Struct<{
3427
3515
  /** The index-side status code (first porcelain column). */
3428
3516
  readonly x: Schema.Literals<readonly [" ", "M", "T", "A", "D", "R", "C", "U", "?", "!"]>;
@@ -3438,7 +3526,209 @@ declare const StatusEntry_base: Schema.Class<StatusEntry, Schema.Struct<{
3438
3526
  *
3439
3527
  * @public
3440
3528
  */
3441
- declare class StatusEntry extends StatusEntry_base {}
3529
+ declare class StatusEntry extends StatusEntry_base {
3530
+ /**
3531
+ * Renders this entry back to one porcelain-shaped line: `XY <path>`.
3532
+ *
3533
+ * @remarks
3534
+ * **The rename convention is decided here, once, for every consumer.** By
3535
+ * default a rename/copy entry renders its NEW path only — `path` IS the
3536
+ * entry's current path, the one a line-oriented downstream can actually
3537
+ * open — which is a deliberate divergence from git's own non-`-z`
3538
+ * rendering (`orig -> new`). The arrow form is ambiguous to naive
3539
+ * line/whitespace splitters (paths may contain spaces, or a literal
3540
+ * `" -> "`), so it is opt-in via `renames: "arrow"` for consumers that
3541
+ * want git parity.
3542
+ *
3543
+ * A second recorded divergence: git's non-`-z` porcelain C-quotes paths
3544
+ * containing special characters; this renderer emits paths raw. It exists
3545
+ * for whitespace-insensitive text consumers — a machine parser should
3546
+ * consume the decoded {@link StatusEntry} values (or `-z` output)
3547
+ * directly, never re-parse this rendering.
3548
+ */
3549
+ toLine(options?: StatusRenderOptions): string;
3550
+ /**
3551
+ * Renders entries back to porcelain-shaped text: one {@link StatusEntry.toLine}
3552
+ * line per entry, newline-joined, no trailing newline.
3553
+ *
3554
+ * @remarks
3555
+ * The route back from `Git.status`'s parsed entries to line-oriented text,
3556
+ * so a consumer whose downstream contract is porcelain-shaped text does
3557
+ * not hand-roll its own renderer (and re-decide the rename convention —
3558
+ * see {@link StatusEntry.toLine} for that decision). An empty array
3559
+ * renders as the empty string.
3560
+ */
3561
+ static readonly format: (entries: ReadonlyArray<StatusEntry>, options?: StatusRenderOptions) => string;
3562
+ }
3563
+ declare const SubmoduleStatusEntry_base: Schema.Class<SubmoduleStatusEntry, Schema.Struct<{
3564
+ /** The decoded state prefix. */
3565
+ readonly state: Schema.Literals<readonly ["current", "uninitialized", "outOfSync", "conflict"]>;
3566
+ /** The submodule's checked-out (or, uninitialized, gitlink) commit sha. */
3567
+ readonly sha: Schema.String;
3568
+ /** The submodule's path relative to the superproject root. */
3569
+ readonly path: Schema.String;
3570
+ /** The `git describe` suffix, present only for initialized submodules. */
3571
+ readonly describe: Schema.optionalKey<Schema.String>;
3572
+ }>, {}>;
3573
+ /**
3574
+ * One line of a `git submodule status` listing.
3575
+ *
3576
+ * @remarks
3577
+ * The `state` decodes git's one-character prefix: `" "` → `"current"` (the
3578
+ * checked-out commit matches the index gitlink), `"-"` → `"uninitialized"`,
3579
+ * `"+"` → `"outOfSync"` (the checked-out commit differs from the gitlink),
3580
+ * `"U"` → `"conflict"` (merge conflicts). `describe` carries the
3581
+ * parenthesized `git describe` suffix git appends for initialized
3582
+ * submodules.
3583
+ *
3584
+ * @public
3585
+ */
3586
+ declare class SubmoduleStatusEntry extends SubmoduleStatusEntry_base {}
3587
+ declare const LsRemoteEntry_base: Schema.Class<LsRemoteEntry, Schema.Struct<{
3588
+ /** The sha the advertised ref points at. */
3589
+ readonly sha: Schema.String;
3590
+ /** The full advertised refname, `^{}` peel suffix included. */
3591
+ readonly ref: Schema.String;
3592
+ }>, {}>;
3593
+ /**
3594
+ * One ref a remote advertises, from `git ls-remote`.
3595
+ *
3596
+ * @remarks
3597
+ * `ref` is the FULL refname as advertised (`refs/heads/main`,
3598
+ * `refs/tags/v1`), including the `^{}` suffix on an annotated tag's peeled
3599
+ * entry — an annotated tag appears twice, once as the tag object and once
3600
+ * peeled to its commit.
3601
+ *
3602
+ * @public
3603
+ */
3604
+ declare class LsRemoteEntry extends LsRemoteEntry_base {
3605
+ /**
3606
+ * The human-facing short name of an advertised refname: the
3607
+ * `refs/heads/` / `refs/tags/` / `refs/remotes/` prefix and any `^{}`
3608
+ * peel suffix stripped (`refs/tags/v1^{}` → `v1`).
3609
+ */
3610
+ static readonly shortName: (ref: string) => string;
3611
+ /**
3612
+ * The entries whose short name is a NEAR MISS for `ref`: not an exact
3613
+ * match, but ending in `ref` right behind a separator (`@`, `/`, `-`,
3614
+ * `_`) — the monorepo-prefixed-tag case, where a caller asks for
3615
+ * `4.0.0-beta.101` and the remote advertises `effect@4.0.0-beta.101`.
3616
+ *
3617
+ * @remarks
3618
+ * A pure, decode-side helper for validate-before-mutate flows: run
3619
+ * `lsRemote`, look for the wanted ref, and when it is absent hand the
3620
+ * listing to this to compute a suggestion. Deliberately a helper on the
3621
+ * ENTRY value rather than behavior baked into the service — the service
3622
+ * returns the full listing and the caller owns the matching policy. An
3623
+ * annotated tag's peeled `^{}` entry shares its base short name, so a
3624
+ * near miss on such a tag can surface both of its entries.
3625
+ */
3626
+ static readonly nearMatches: (entries: ReadonlyArray<LsRemoteEntry>, ref: string) => ReadonlyArray<LsRemoteEntry>;
3627
+ }
3628
+ declare const StashEntry_base: Schema.Class<StashEntry, Schema.Struct<{
3629
+ /** The reflog selector (`stash@{0}`) — the index other stash methods take. */
3630
+ readonly ref: Schema.String;
3631
+ /** The stash commit's sha. */
3632
+ readonly sha: Schema.String;
3633
+ /** The reflog subject: `WIP on <branch>: ...` or `On <branch>: <message>`. */
3634
+ readonly message: Schema.String;
3635
+ }>, {}>;
3636
+ /**
3637
+ * One stash entry, from `git stash list`.
3638
+ *
3639
+ * @public
3640
+ */
3641
+ declare class StashEntry extends StashEntry_base {}
3642
+ declare const BranchEntry_base: Schema.Class<BranchEntry, Schema.Struct<{
3643
+ /** The short branch name (`main`, or `origin/main` for a remote branch). */
3644
+ readonly name: Schema.String;
3645
+ /** The branch tip's sha. */
3646
+ readonly sha: Schema.String;
3647
+ /** Whether this branch is checked out in the current working tree. */
3648
+ readonly current: Schema.Boolean;
3649
+ }>, {}>;
3650
+ /**
3651
+ * One local (or remote-tracking) branch, from `git branch --list`.
3652
+ *
3653
+ * @public
3654
+ */
3655
+ declare class BranchEntry extends BranchEntry_base {}
3656
+ declare const RefEntry_base: Schema.Class<RefEntry, Schema.Struct<{
3657
+ /** The full refname (`refs/tags/v1`). */
3658
+ readonly ref: Schema.String;
3659
+ /** The sha of the object the ref points at. */
3660
+ readonly sha: Schema.String;
3661
+ /**
3662
+ * The pointed-at object's type. An annotated tag is `tag` (the tag
3663
+ * object itself, not its target commit).
3664
+ */
3665
+ readonly objectType: Schema.Literals<readonly ["commit", "tag", "tree", "blob"]>;
3666
+ }>, {}>;
3667
+ /**
3668
+ * One ref, from `git for-each-ref`.
3669
+ *
3670
+ * @public
3671
+ */
3672
+ declare class RefEntry extends RefEntry_base {}
3673
+ declare const ConfigListEntry_base: Schema.Class<ConfigListEntry, Schema.Struct<{
3674
+ /** The canonical dotted key (`section.subsection.key`). */
3675
+ readonly key: Schema.String;
3676
+ /**
3677
+ * The raw value. A valueless key (git's boolean-true shorthand,
3678
+ * `[section]` + bare `key`) surfaces as the empty string — distinguish it
3679
+ * with `configGetAll` if the difference matters.
3680
+ */
3681
+ readonly value: Schema.String;
3682
+ }>, {}>;
3683
+ /**
3684
+ * One configuration entry, from `git config --list`.
3685
+ *
3686
+ * @public
3687
+ */
3688
+ declare class ConfigListEntry extends ConfigListEntry_base {}
3689
+ declare const WorktreeEntry_base: Schema.Class<WorktreeEntry, Schema.Struct<{
3690
+ /** The working tree's absolute path. */
3691
+ readonly path: Schema.String;
3692
+ /** The checked-out commit sha; absent for a bare repository entry. */
3693
+ readonly head: Schema.optionalKey<Schema.String>;
3694
+ /** The checked-out branch's full refname; absent when detached or bare. */
3695
+ readonly branch: Schema.optionalKey<Schema.String>;
3696
+ /** Whether the working tree is in detached-HEAD state. */
3697
+ readonly detached: Schema.Boolean;
3698
+ /** Whether the entry is the bare repository itself. */
3699
+ readonly bare: Schema.Boolean;
3700
+ /** Present when the worktree is locked; holds the lock reason (possibly empty). */
3701
+ readonly locked: Schema.optionalKey<Schema.String>;
3702
+ /** Present when the worktree is prunable; holds the reason (possibly empty). */
3703
+ readonly prunable: Schema.optionalKey<Schema.String>;
3704
+ }>, {}>;
3705
+ /**
3706
+ * One working tree, from `git worktree list --porcelain`.
3707
+ *
3708
+ * @public
3709
+ */
3710
+ declare class WorktreeEntry extends WorktreeEntry_base {}
3711
+ declare const LsFilesEntry_base: Schema.Class<LsFilesEntry, Schema.Struct<{
3712
+ /** The entry's file mode, e.g. `100644` — `160000` for a gitlink. */
3713
+ readonly mode: Schema.String;
3714
+ /** The staged object id. */
3715
+ readonly oid: Schema.String;
3716
+ /** The merge stage: `0` normally; `1`/`2`/`3` during an unresolved merge. */
3717
+ readonly stage: Schema.Number;
3718
+ /** The entry's path, relative to `cwd`. May contain spaces or newlines. */
3719
+ readonly path: Schema.String;
3720
+ }>, {}>;
3721
+ /**
3722
+ * One index (staging area) entry, from `git ls-files --stage`.
3723
+ *
3724
+ * @remarks
3725
+ * The index-side sibling of {@link LsTreeEntry}: this is the ONLY place a
3726
+ * staged-but-uncommitted gitlink (`mode` `160000`) is visible — `lsTree`
3727
+ * reads the committed tree and misses exactly that window.
3728
+ *
3729
+ * @public
3730
+ */
3731
+ declare class LsFilesEntry extends LsFilesEntry_base {}
3442
3732
  /**
3443
3733
  * The {@link Git} service shape.
3444
3734
  *
@@ -3529,6 +3819,115 @@ interface GitShape {
3529
3819
  readonly remote?: string;
3530
3820
  readonly depth?: number;
3531
3821
  }) => Effect.Effect<void, GitCommandError | NotARepositoryError | UnknownRefError>;
3822
+ /**
3823
+ * Mutating: `git fetch --unshallow <remote>` — converts a shallow clone
3824
+ * into a complete one by fetching all missing history from
3825
+ * `options.remote` (default `origin`).
3826
+ *
3827
+ * `--unshallow` is a distinct mode, not a depth value: **git rejects it in
3828
+ * a repository that is not shallow**, with
3829
+ * `--unshallow on a complete repository does not make sense` — and this
3830
+ * method deliberately does NOT tolerate that; the failure surfaces typed
3831
+ * as `GitCommandError`, because swallowing it would also swallow every
3832
+ * other fetch failure shape. The caller owns the guard: probe with
3833
+ * `isShallow` first and skip the fetch when the repository is already
3834
+ * complete.
3835
+ */
3836
+ readonly fetchUnshallow: (cwd: string, options?: {
3837
+ readonly remote?: string;
3838
+ }) => Effect.Effect<void, GitCommandError | NotARepositoryError | UnknownRefError>;
3839
+ /**
3840
+ * `git rev-parse --is-shallow-repository` — whether the repository is a
3841
+ * shallow clone.
3842
+ *
3843
+ * A dedicated predicate, deliberately not folded into `revParse`: that
3844
+ * method's contract is "resolve this REF"; this one takes no ref and
3845
+ * answers a repository-shape question. The intended pairing is
3846
+ * `isShallow` → `fetchUnshallow`.
3847
+ */
3848
+ readonly isShallow: (cwd: string) => Effect.Effect<boolean, GitCommandError | NotARepositoryError | UnknownRefError>;
3849
+ /**
3850
+ * Mutating: `git reset --soft|--mixed|--hard [<ref>]` — moves `HEAD` (and,
3851
+ * per `options.mode`, the index and working tree) to `options.ref`
3852
+ * (default `HEAD`, i.e. unstage/discard against the current commit).
3853
+ *
3854
+ * The restore-before-retry primitive: **a failed reset fails loudly and
3855
+ * typed** (`GitCommandError` on any non-zero exit), never a silent no-op —
3856
+ * a reset that silently did nothing would hand a retry of a
3857
+ * non-idempotent operation the same dirty tree. `mode` defaults to
3858
+ * `"mixed"` (git's own default), emitted explicitly in the argv.
3859
+ */
3860
+ readonly reset: (cwd: string, options?: {
3861
+ readonly mode?: "soft" | "mixed" | "hard";
3862
+ readonly ref?: string;
3863
+ }) => Effect.Effect<void, GitCommandError | NotARepositoryError | UnknownRefError>;
3864
+ /**
3865
+ * Mutating: `git clean --force [-d] [-x] [-- <paths>...]` — deletes
3866
+ * untracked files (and, with `options.directories`, untracked directories;
3867
+ * with `options.ignored`, ignored files too), optionally scoped to
3868
+ * `options.paths`.
3869
+ *
3870
+ * `--force` is unconditional: this member exists so a consumer can restore
3871
+ * a tree to a known state before retrying a non-idempotent operation, and
3872
+ * without it git refuses to clean under the default `clean.requireForce`
3873
+ * config — **a clean that silently did nothing corrupts the retry**. Any
3874
+ * non-zero exit fails loudly as `GitCommandError`.
3875
+ */
3876
+ readonly clean: (cwd: string, options?: {
3877
+ readonly directories?: boolean;
3878
+ readonly ignored?: boolean;
3879
+ readonly paths?: ReadonlyArray<string>;
3880
+ }) => Effect.Effect<void, GitCommandError | NotARepositoryError | UnknownRefError>;
3881
+ /**
3882
+ * Mutating: `git restore [--source <ref>] [--staged] [--worktree] -- <paths...>`
3883
+ * — restores `paths` from the index, or from `options.source`. The
3884
+ * `checkout -- .`-shaped operation: `restore(cwd, ["."])` discards all
3885
+ * unstaged working-tree changes.
3886
+ *
3887
+ * A separate member deliberately, because `checkout`'s option-injection
3888
+ * guard refuses `--` and option-like refs by design and stays that way.
3889
+ * `restore`'s paths always sit behind a literal `--`, so they are
3890
+ * injection-safe by construction; only `options.source` is a guarded ref.
3891
+ * With neither `staged` nor `worktree` set, git restores the working tree.
3892
+ */
3893
+ readonly restore: (cwd: string, paths: ReadonlyArray<string>, options?: {
3894
+ readonly source?: string;
3895
+ readonly staged?: boolean;
3896
+ readonly worktree?: boolean;
3897
+ }) => Effect.Effect<void, GitCommandError | NotARepositoryError | UnknownRefError>;
3898
+ /**
3899
+ * Mutating: `git branch [-f] <name> [<start-point>]` — creates a branch,
3900
+ * optionally from `options.startPoint`; `options.checkout` switches to it
3901
+ * on creation (`git checkout -b <name> [<start-point>]`), and
3902
+ * `options.force` resets the branch if it already exists (`branch -f`,
3903
+ * or `checkout -B` with `checkout`).
3904
+ *
3905
+ * Branch creation is a branch-member concern, not a `checkout` option:
3906
+ * `checkout`'s contract stays "move to an existing ref" with its
3907
+ * option-like-ref refusal intact. Both `name` and `startPoint` are
3908
+ * guarded — an option-like value is refused typed before any spawn.
3909
+ *
3910
+ * `force` with `checkout` replaces the delete-then-create longhand — a
3911
+ * swallowed `branchDelete(force: true)` followed by a plain create —
3912
+ * which papers over a real edge: `git branch -D` refuses to delete the
3913
+ * currently checked-out branch, so on a runner already sitting on that
3914
+ * branch the swallowed delete fails and the create then fails for real.
3915
+ * `checkout -B` handles both states in one invocation.
3916
+ */
3917
+ readonly branchCreate: (cwd: string, name: string, options?: {
3918
+ readonly startPoint?: string;
3919
+ readonly checkout?: boolean;
3920
+ readonly force?: boolean;
3921
+ }) => Effect.Effect<void, GitCommandError | NotARepositoryError | UnknownRefError>;
3922
+ /**
3923
+ * Mutating: `git branch -d <name>` (or `-D` with `options.force`) —
3924
+ * deletes a local branch. The default `-d` refuses a branch that is not
3925
+ * fully merged — a typed `GitCommandError`, which is usually the honest
3926
+ * answer; `force: true` deletes regardless.
3927
+ */
3928
+ readonly branchDelete: (cwd: string, name: string, options?: {
3929
+ readonly force?: boolean;
3930
+ }) => Effect.Effect<void, GitCommandError | NotARepositoryError | UnknownRefError>;
3532
3931
  /**
3533
3932
  * Mutating: `git submodule update [--init] [--depth <n>] [-- <paths>...]`
3534
3933
  * — updates registered submodules in the working tree, optionally
@@ -3550,6 +3949,85 @@ interface GitShape {
3550
3949
  readonly path: string;
3551
3950
  readonly depth?: number;
3552
3951
  }) => Effect.Effect<void, GitCommandError | NotARepositoryError | UnknownRefError>;
3952
+ /**
3953
+ * `git submodule status [--recursive] [-- <paths>...]` — one
3954
+ * {@link SubmoduleStatusEntry} per registered submodule, decoding git's
3955
+ * state prefix (`current` / `uninitialized` / `outOfSync` / `conflict`).
3956
+ *
3957
+ * The output is line-based (git offers no `-z` mode here), so a submodule
3958
+ * path containing a newline would corrupt the parse — a git-imposed
3959
+ * limitation, recorded on the entry class.
3960
+ */
3961
+ readonly submoduleStatus: (cwd: string, options?: {
3962
+ readonly paths?: ReadonlyArray<string>;
3963
+ readonly recursive?: boolean;
3964
+ }) => Effect.Effect<ReadonlyArray<SubmoduleStatusEntry>, GitCommandError | NotARepositoryError | UnknownRefError>;
3965
+ /**
3966
+ * Mutating: `git submodule init [-- <paths>...]` — registers submodules
3967
+ * from `.gitmodules` into `.git/config` (all of them, or only
3968
+ * `options.paths`) without cloning or checking anything out.
3969
+ */
3970
+ readonly submoduleInit: (cwd: string, options?: {
3971
+ readonly paths?: ReadonlyArray<string>;
3972
+ }) => Effect.Effect<void, GitCommandError | NotARepositoryError | UnknownRefError>;
3973
+ /**
3974
+ * Mutating: `git submodule deinit [--force] (--all | -- <paths>...)` —
3975
+ * unregisters submodules: clears their working trees and removes their
3976
+ * `.git/config` registration. Requires either `options.paths` or
3977
+ * `options.all: true`; neither is refused typed before any spawn, exactly
3978
+ * as git itself would refuse it. `options.force` discards local changes
3979
+ * in the submodule working tree.
3980
+ */
3981
+ readonly submoduleDeinit: (cwd: string, options: {
3982
+ readonly paths?: ReadonlyArray<string>;
3983
+ readonly all?: boolean;
3984
+ readonly force?: boolean;
3985
+ }) => Effect.Effect<void, GitCommandError | NotARepositoryError | UnknownRefError>;
3986
+ /**
3987
+ * Mutating: `git submodule sync [--recursive] [-- <paths>...]` — re-copies
3988
+ * each submodule's URL from `.gitmodules` into `.git/config` (and the
3989
+ * submodule's own `remote.origin.url`), so a `.gitmodules` URL change
3990
+ * actually reaches git's live configuration.
3991
+ */
3992
+ readonly submoduleSync: (cwd: string, options?: {
3993
+ readonly paths?: ReadonlyArray<string>;
3994
+ readonly recursive?: boolean;
3995
+ }) => Effect.Effect<void, GitCommandError | NotARepositoryError | UnknownRefError>;
3996
+ /**
3997
+ * Mutating: `git submodule set-url -- <path> <url>` — rewrites the
3998
+ * submodule's URL in `.gitmodules` and synchronizes it into `.git/config`.
3999
+ *
4000
+ * The url never surfaces raw in an error — an embedded `userinfo@`
4001
+ * credential is masked in `GitCommandError.args`/`.message` — and the
4002
+ * method's span annotates `cwd` and `path` only.
4003
+ */
4004
+ readonly submoduleSetUrl: (cwd: string, path: string, url: string) => Effect.Effect<void, GitCommandError | NotARepositoryError | UnknownRefError>;
4005
+ /**
4006
+ * Mutating: `git submodule set-branch (--branch <branch> | --default) -- <path>`
4007
+ * — records the branch the submodule tracks in `.gitmodules`, or clears
4008
+ * it back to the default when `options.branch` is omitted.
4009
+ */
4010
+ readonly submoduleSetBranch: (cwd: string, path: string, options?: {
4011
+ readonly branch?: string;
4012
+ }) => Effect.Effect<void, GitCommandError | NotARepositoryError | UnknownRefError>;
4013
+ /**
4014
+ * Mutating: `git submodule absorbgitdirs [-- <paths>...]` — moves each
4015
+ * submodule's embedded `.git` directory into the superproject's
4016
+ * `.git/modules/` and leaves a gitfile pointer behind.
4017
+ */
4018
+ readonly submoduleAbsorbgitdirs: (cwd: string, options?: {
4019
+ readonly paths?: ReadonlyArray<string>;
4020
+ }) => Effect.Effect<void, GitCommandError | NotARepositoryError | UnknownRefError>;
4021
+ /**
4022
+ * Mutating: `git submodule foreach [--recursive] <command>` — runs one
4023
+ * shell command string in every checked-out submodule and returns the
4024
+ * collected stdout. The command can mutate anything, which is why the
4025
+ * method is marked mutating regardless of what it runs; a command
4026
+ * beginning with `-` is refused typed before any spawn.
4027
+ */
4028
+ readonly submoduleForeach: (cwd: string, command: string, options?: {
4029
+ readonly recursive?: boolean;
4030
+ }) => Effect.Effect<string, GitCommandError | NotARepositoryError | UnknownRefError>;
3553
4031
  /**
3554
4032
  * Mutating: `git sparse-checkout set (--cone | --no-cone) <patterns...>`
3555
4033
  * — rewrites which paths are checked out in the working tree to
@@ -3562,6 +4040,10 @@ interface GitShape {
3562
4040
  * Mutating: `git config [-f <file>] <key> <value>` — writes `value` for
3563
4041
  * `key` into the repository config, or into `options.file` when given
3564
4042
  * (e.g. `.gitmodules`).
4043
+ *
4044
+ * The value never surfaces in an error: a failing `configSet` carries
4045
+ * `<redacted>` in `GitCommandError.args` and `.message`, and the method's
4046
+ * span annotates `key` and `file` only.
3565
4047
  */
3566
4048
  readonly configSet: (cwd: string, key: string, value: string, options?: {
3567
4049
  readonly file?: string;
@@ -3622,21 +4104,296 @@ interface GitShape {
3622
4104
  readonly commitInfo: (cwd: string, ref?: string) => Effect.Effect<CommitInfo, GitCommandError | NotARepositoryError | UnknownRefError>;
3623
4105
  /** `git status --porcelain -z` — the working tree's porcelain status listing. */
3624
4106
  readonly status: (cwd: string) => Effect.Effect<ReadonlyArray<StatusEntry>, GitCommandError | NotARepositoryError | UnknownRefError>;
4107
+ /**
4108
+ * `git ls-remote [--heads] [--tags] <remote> [<patterns>...]` — the refs
4109
+ * `remote` advertises, as {@link LsRemoteEntry} values, optionally
4110
+ * filtered to branch heads and/or tags and/or shell-glob patterns.
4111
+ *
4112
+ * The one read that talks to the NETWORK. Auth failure and an unreachable
4113
+ * remote stay {@link GitCommandError} deliberately — no consumer branches
4114
+ * on them, so they carry no dedicated type. The validate-before-mutate
4115
+ * consumer story: look for the wanted ref in the listing, and on a miss
4116
+ * hand the entries to `LsRemoteEntry.nearMatches` for a suggestion (the
4117
+ * monorepo-prefixed-tag case, `effect@<ref>`). `remote` may be a URL; an
4118
+ * embedded credential never surfaces in an error value.
4119
+ */
4120
+ readonly lsRemote: (cwd: string, remote: string, options?: {
4121
+ readonly heads?: boolean;
4122
+ readonly tags?: boolean;
4123
+ readonly patterns?: ReadonlyArray<string>;
4124
+ }) => Effect.Effect<ReadonlyArray<LsRemoteEntry>, GitCommandError | NotARepositoryError | UnknownRefError>;
4125
+ /**
4126
+ * Mutating: `git remote add <name> <url>` — registers a new remote.
4127
+ * `url`'s embedded credential (if any) never surfaces in an error value,
4128
+ * and the method's span annotates `name` only.
4129
+ */
4130
+ readonly remoteAdd: (cwd: string, name: string, url: string) => Effect.Effect<void, GitCommandError | NotARepositoryError | UnknownRefError>;
4131
+ /**
4132
+ * Mutating: `git remote remove <name>` — deletes a remote, its
4133
+ * remote-tracking refs and its configuration. A missing remote fails
4134
+ * loudly as {@link GitCommandError} — probe with `remoteUrl` first when
4135
+ * idempotency is wanted.
4136
+ */
4137
+ readonly remoteRemove: (cwd: string, name: string) => Effect.Effect<void, GitCommandError | NotARepositoryError | UnknownRefError>;
4138
+ /**
4139
+ * Mutating: `git remote set-url <name> <url>` — rewrites a remote's fetch
4140
+ * URL. `url`'s embedded credential (if any) never surfaces in an error
4141
+ * value, and the method's span annotates `name` only.
4142
+ */
4143
+ readonly remoteSetUrl: (cwd: string, name: string, url: string) => Effect.Effect<void, GitCommandError | NotARepositoryError | UnknownRefError>;
4144
+ /**
4145
+ * Mutating: `git stash push [--include-untracked] [-m <message>] [-- <paths>...]`
4146
+ * — saves the working-tree (and index) state onto the stash stack and
4147
+ * resets the tree to `HEAD`.
4148
+ */
4149
+ readonly stashPush: (cwd: string, options?: {
4150
+ readonly message?: string;
4151
+ readonly includeUntracked?: boolean;
4152
+ readonly paths?: ReadonlyArray<string>;
4153
+ }) => Effect.Effect<void, GitCommandError | NotARepositoryError | UnknownRefError>;
4154
+ /**
4155
+ * Mutating: `git stash pop [stash@{n}]` — applies a stash entry
4156
+ * (`options.index`, default the latest) and drops it on success.
4157
+ *
4158
+ * The two branchable failures are typed: {@link DirtyWorktreeError} when
4159
+ * local changes would be overwritten (the tree is untouched), and
4160
+ * {@link MergeConflictError} when the apply stopped on conflicts — in
4161
+ * that case the stash entry is KEPT, and the caller owns resolving. A
4162
+ * non-integer index is refused typed before any spawn.
4163
+ */
4164
+ readonly stashPop: (cwd: string, options?: {
4165
+ readonly index?: number;
4166
+ }) => Effect.Effect<void, GitCommandError | NotARepositoryError | UnknownRefError | MergeConflictError | DirtyWorktreeError>;
4167
+ /**
4168
+ * Mutating: `git stash apply [stash@{n}]` — applies a stash entry and
4169
+ * keeps it on the stack. Fails exactly like `stashPop`
4170
+ * ({@link DirtyWorktreeError} / {@link MergeConflictError} are the
4171
+ * branchable shapes).
4172
+ */
4173
+ readonly stashApply: (cwd: string, options?: {
4174
+ readonly index?: number;
4175
+ }) => Effect.Effect<void, GitCommandError | NotARepositoryError | UnknownRefError | MergeConflictError | DirtyWorktreeError>;
4176
+ /**
4177
+ * Mutating: `git stash drop [stash@{n}]` — deletes a stash entry
4178
+ * (`options.index`, default the latest) without applying it.
4179
+ */
4180
+ readonly stashDrop: (cwd: string, options?: {
4181
+ readonly index?: number;
4182
+ }) => Effect.Effect<void, GitCommandError | NotARepositoryError | UnknownRefError>;
4183
+ /**
4184
+ * `git stash list -z --format=%gd%x1f%H%x1f%gs` — every stash entry as a
4185
+ * {@link StashEntry} (reflog selector, sha, subject). The entry's
4186
+ * position in the returned array IS its current index — `entries[2]` is
4187
+ * `stash@{2}` — which is what the index-taking stash methods consume.
4188
+ */
4189
+ readonly stashList: (cwd: string) => Effect.Effect<ReadonlyArray<StashEntry>, GitCommandError | NotARepositoryError | UnknownRefError>;
4190
+ /**
4191
+ * `git branch --list [--remotes | --all]` — every branch as a
4192
+ * {@link BranchEntry} (short name, tip sha, current marker), via the
4193
+ * NUL-separated for-each-ref format. `all` wins when both flags are set.
4194
+ */
4195
+ readonly branchList: (cwd: string, options?: {
4196
+ readonly remotes?: boolean;
4197
+ readonly all?: boolean;
4198
+ }) => Effect.Effect<ReadonlyArray<BranchEntry>, GitCommandError | NotARepositoryError | UnknownRefError>;
4199
+ /**
4200
+ * Mutating: `git tag [--force] [-m <message>] <name> [<ref>]` — creates a
4201
+ * lightweight tag at `options.ref` (default `HEAD`), or an annotated one
4202
+ * when `options.message` is given. An existing tag fails loudly unless
4203
+ * `options.force` is set.
4204
+ */
4205
+ readonly tagCreate: (cwd: string, name: string, options?: {
4206
+ readonly ref?: string;
4207
+ readonly message?: string;
4208
+ readonly force?: boolean;
4209
+ }) => Effect.Effect<void, GitCommandError | NotARepositoryError | UnknownRefError>;
4210
+ /** Mutating: `git tag --delete <name>` — deletes a local tag. */
4211
+ readonly tagDelete: (cwd: string, name: string) => Effect.Effect<void, GitCommandError | NotARepositoryError | UnknownRefError>;
4212
+ /**
4213
+ * `git tag --list [<pattern>]` — tag names, optionally filtered by a
4214
+ * shell-glob `options.pattern`.
4215
+ */
4216
+ readonly tagList: (cwd: string, options?: {
4217
+ readonly pattern?: string;
4218
+ }) => Effect.Effect<ReadonlyArray<string>, GitCommandError | NotARepositoryError | UnknownRefError>;
4219
+ /**
4220
+ * `git for-each-ref [<patterns>...]` — every matching ref as a
4221
+ * {@link RefEntry} (full refname, sha, object type), via this package's
4222
+ * fixed `%(refname)%00%(objectname)%00%(objecttype)` format.
4223
+ */
4224
+ readonly forEachRef: (cwd: string, options?: {
4225
+ readonly patterns?: ReadonlyArray<string>;
4226
+ }) => Effect.Effect<ReadonlyArray<RefEntry>, GitCommandError | NotARepositoryError | UnknownRefError>;
4227
+ /**
4228
+ * `git rev-list [--max-count=<n>] [--first-parent] <ref>` — the commit
4229
+ * shas reachable from `ref` (which may be a range, `main..feat`), newest
4230
+ * first. A non-integer `options.limit` is refused typed before any spawn.
4231
+ */
4232
+ readonly revList: (cwd: string, ref: string, options?: {
4233
+ readonly limit?: number;
4234
+ readonly firstParent?: boolean;
4235
+ }) => Effect.Effect<ReadonlyArray<string>, GitCommandError | NotARepositoryError | UnknownRefError>;
4236
+ /**
4237
+ * Mutating: `git commit [--all] [--allow-empty] [--amend] [--author=<author>] -m <message>`
4238
+ * — records a commit. The message rides argv; committer identity comes
4239
+ * from the caller's ENVIRONMENT (this package sets only `LC_ALL`), and
4240
+ * `options.author` is the explicit `--author=` override. "Nothing to
4241
+ * commit" fails loudly as {@link GitCommandError}.
4242
+ */
4243
+ readonly commit: (cwd: string, message: string, options?: {
4244
+ readonly all?: boolean;
4245
+ readonly allowEmpty?: boolean;
4246
+ readonly amend?: boolean;
4247
+ readonly author?: string;
4248
+ }) => Effect.Effect<void, GitCommandError | NotARepositoryError | UnknownRefError>;
4249
+ /**
4250
+ * Mutating: `git push [--force | --force-with-lease] [--tags] [--set-upstream] <remote> [<refspec>]`
4251
+ * — updates remote refs.
4252
+ *
4253
+ * A rejected push — the remote moved (`fetch first` /
4254
+ * `non-fast-forward`), or a `--force-with-lease` lease failure
4255
+ * (`stale info`) — fails typed as {@link NonFastForwardError}, the signal
4256
+ * a fetch-then-retry fallback branches on. Every other failure stays
4257
+ * {@link GitCommandError}. `remote` may be a URL; an embedded credential
4258
+ * never surfaces in an error value.
4259
+ */
4260
+ readonly push: (cwd: string, options?: {
4261
+ readonly remote?: string;
4262
+ readonly refspec?: string;
4263
+ readonly force?: boolean;
4264
+ readonly forceWithLease?: boolean;
4265
+ readonly tags?: boolean;
4266
+ readonly setUpstream?: boolean;
4267
+ }) => Effect.Effect<void, GitCommandError | NotARepositoryError | UnknownRefError | NonFastForwardError>;
4268
+ /**
4269
+ * Mutating: `git pull [--rebase] [--ff-only] <remote> [<ref>]` — fetches
4270
+ * and integrates.
4271
+ *
4272
+ * The two branchable failures are typed: {@link DirtyWorktreeError} when
4273
+ * local modifications block the merge before it starts (the tree is
4274
+ * untouched — commit or stash first), and {@link MergeConflictError} when
4275
+ * the merge stopped on conflicts (markers are in the tree; resolve or
4276
+ * abort). `remote` may be a URL; an embedded credential never surfaces in
4277
+ * an error value.
4278
+ */
4279
+ readonly pull: (cwd: string, options?: {
4280
+ readonly remote?: string;
4281
+ readonly ref?: string;
4282
+ readonly rebase?: boolean;
4283
+ readonly ffOnly?: boolean;
4284
+ }) => Effect.Effect<void, GitCommandError | NotARepositoryError | UnknownRefError | MergeConflictError | DirtyWorktreeError>;
4285
+ /**
4286
+ * `git config [-f <file>] --list -z` — every configuration entry in scope
4287
+ * (or in `options.file` only) as {@link ConfigListEntry} values. `-z`
4288
+ * keeps multi-line values lossless.
4289
+ */
4290
+ readonly configList: (cwd: string, options?: {
4291
+ readonly file?: string;
4292
+ }) => Effect.Effect<ReadonlyArray<ConfigListEntry>, GitCommandError | NotARepositoryError | UnknownRefError>;
4293
+ /**
4294
+ * `git config [-f <file>] --get-all -z <key>` — every value of a
4295
+ * (possibly multi-valued) key, in order. An unset key degrades to the
4296
+ * empty array, never an error — the multi-valued sibling of `configGet`'s
4297
+ * `Option.none`.
4298
+ */
4299
+ readonly configGetAll: (cwd: string, key: string, options?: {
4300
+ readonly file?: string;
4301
+ }) => Effect.Effect<ReadonlyArray<string>, GitCommandError | NotARepositoryError | UnknownRefError>;
4302
+ /**
4303
+ * Mutating: `git config [-f <file>] (--unset | --unset-all) <key>` —
4304
+ * removes `key` (or, with `options.all`, every value of a multi-valued
4305
+ * key). Unsetting a key that was never set fails LOUDLY (git exits 5) —
4306
+ * an unset that silently did nothing is indistinguishable from one that
4307
+ * worked; probe with `configGet` first when idempotency is wanted.
4308
+ */
4309
+ readonly configUnset: (cwd: string, key: string, options?: {
4310
+ readonly file?: string;
4311
+ readonly all?: boolean;
4312
+ }) => Effect.Effect<void, GitCommandError | NotARepositoryError | UnknownRefError>;
4313
+ /**
4314
+ * Mutating: `git rm [--cached] [-r] [--force] -- <paths...>` — removes
4315
+ * `paths` from the index and (without `options.cached`) the working tree.
4316
+ * `cached: true` is the unstage-but-keep-file form a submodule removal
4317
+ * sequence needs.
4318
+ */
4319
+ readonly rm: (cwd: string, paths: ReadonlyArray<string>, options?: {
4320
+ readonly cached?: boolean;
4321
+ readonly recursive?: boolean;
4322
+ readonly force?: boolean;
4323
+ }) => Effect.Effect<void, GitCommandError | NotARepositoryError | UnknownRefError>;
4324
+ /**
4325
+ * Mutating: `git mv [--force] -- <source> <destination>` — moves or
4326
+ * renames a tracked path, updating the index and the working tree
4327
+ * together.
4328
+ */
4329
+ readonly mv: (cwd: string, source: string, destination: string, options?: {
4330
+ readonly force?: boolean;
4331
+ }) => Effect.Effect<void, GitCommandError | NotARepositoryError | UnknownRefError>;
4332
+ /**
4333
+ * `git check-ignore -z --stdin` — the subset of `paths` git would ignore,
4334
+ * predicate-shaped: paths in, the ignored ones back. Paths are fed via
4335
+ * STDIN (NUL-separated both directions), so nothing caller-controlled
4336
+ * enters the argv and special-character paths survive unquoted. No path
4337
+ * ignored degrades to the empty array, never an error.
4338
+ */
4339
+ readonly checkIgnore: (cwd: string, paths: ReadonlyArray<string>) => Effect.Effect<ReadonlyArray<string>, GitCommandError | NotARepositoryError | UnknownRefError>;
4340
+ /**
4341
+ * Mutating: `git worktree add [--force] [--detach] <path> [<ref>]` —
4342
+ * creates a linked working tree at `path`, checked out at `options.ref`
4343
+ * (or a branch named after `path`'s basename).
4344
+ */
4345
+ readonly worktreeAdd: (cwd: string, path: string, options?: {
4346
+ readonly ref?: string;
4347
+ readonly detach?: boolean;
4348
+ readonly force?: boolean;
4349
+ }) => Effect.Effect<void, GitCommandError | NotARepositoryError | UnknownRefError>;
4350
+ /**
4351
+ * `git worktree list --porcelain -z` — every working tree (the main one
4352
+ * first) as a {@link WorktreeEntry}.
4353
+ */
4354
+ readonly worktreeList: (cwd: string) => Effect.Effect<ReadonlyArray<WorktreeEntry>, GitCommandError | NotARepositoryError | UnknownRefError>;
4355
+ /**
4356
+ * Mutating: `git worktree remove [--force] <path>` — removes a linked
4357
+ * working tree. A dirty worktree fails loudly unless `options.force` is
4358
+ * set.
4359
+ */
4360
+ readonly worktreeRemove: (cwd: string, path: string, options?: {
4361
+ readonly force?: boolean;
4362
+ }) => Effect.Effect<void, GitCommandError | NotARepositoryError | UnknownRefError>;
4363
+ /**
4364
+ * `git ls-files --stage -z [-- <pathspec>...]` — every INDEX entry as an
4365
+ * {@link LsFilesEntry} (mode, oid, merge stage, path), optionally scoped
4366
+ * to `options.pathspec`.
4367
+ *
4368
+ * The index-side sibling of `lsTree`: the only read that sees a
4369
+ * staged-but-uncommitted gitlink (`160000 <oid> 0 <path>`) — the state a
4370
+ * stage-without-commit window (a submodule pin/add) deliberately
4371
+ * produces, which a HEAD-side `lsTree` misreports.
4372
+ */
4373
+ readonly lsFiles: (cwd: string, options?: {
4374
+ readonly pathspec?: ReadonlyArray<string>;
4375
+ }) => Effect.Effect<ReadonlyArray<LsFilesEntry>, GitCommandError | NotARepositoryError | UnknownRefError>;
3625
4376
  }
3626
4377
  declare const Git_base: Context.ServiceClass<Git, "@effected/git/Git", GitShape>;
3627
4378
  /**
3628
4379
  * Typed git introspection over core's `ChildProcessSpawner`: read a
3629
- * repository's state at any ref without checking it out, plus the mutating
3630
- * tier (`checkout`, `fetch`, `fetchAny`, `submoduleUpdate`, `submoduleAdd`,
3631
- * `sparseCheckoutSet`, `configSet`, `add`) that changes it.
4380
+ * repository's state at any ref without checking it out (including the
4381
+ * network read `lsRemote` and the index read `lsFiles`), plus the mutating
4382
+ * tier checkout/fetch, the working-tree restore trio and stash, branches
4383
+ * and tags, remotes, worktrees, commit/push/pull, submodules,
4384
+ * sparse-checkout, config writes and staging — that changes it. Every
4385
+ * mutating method's TSDoc opens with the literal word `Mutating:`.
3632
4386
  *
3633
4387
  * @remarks
3634
4388
  * Every method takes `cwd` explicitly and classifies git's stderr/exit-code
3635
4389
  * taxonomy exactly once, in this module's private `classify` step — a
3636
4390
  * spawn-level `PlatformError` and `Cause.TimeoutError` never escape a `Git`
3637
4391
  * method; every failure surfaces as {@link GitCommandError},
3638
- * {@link NotARepositoryError}, or {@link UnknownRefError}, or degrades to
3639
- * the documented non-error (`Option.none`, `false`).
4392
+ * {@link NotARepositoryError}, {@link UnknownRefError}, or one of the three
4393
+ * consumer-branchable classifications ({@link NonFastForwardError} from
4394
+ * `push`; {@link MergeConflictError} and {@link DirtyWorktreeError} from the
4395
+ * merge-shaped `pull` / `stashPop` / `stashApply`), or degrades to the
4396
+ * documented non-error (`Option.none`, `false`, the empty array).
3640
4397
  *
3641
4398
  * Every method whose TSDoc opens "Mutating:" changes the working tree,
3642
4399
  * `HEAD`, the index, the repository config, the object database and
@@ -3645,6 +4402,12 @@ declare const Git_base: Context.ServiceClass<Git, "@effected/git/Git", GitShape>
3645
4402
  * that — a caller running two mutating calls (or a mutating call alongside a
3646
4403
  * read) against one `cwd` at once owns the race.
3647
4404
  *
4405
+ * **Redaction policy (documented, not just convention).** Error values
4406
+ * persist only the constructor's REDACTED argv (see `GitCommandError.args`),
4407
+ * and span annotations carry stable identifiers only — `cwd`, refs, keys,
4408
+ * paths, remote names — never config values and never URLs, which can embed
4409
+ * userinfo. A new method must follow both halves before it ships.
4410
+ *
3648
4411
  * @public
3649
4412
  */
3650
4413
  declare class Git extends Git_base {
@@ -3656,7 +4419,7 @@ declare class Git extends Git_base {
3656
4419
  *
3657
4420
  * @remarks
3658
4421
  * Unlike `WorkspaceDiscovery.makeTest`, **no method here has an honest
3659
- * default** — the shape is twenty-six unrelated git operations, and a
4422
+ * default** — the shape is unrelated git operations, and a
3660
4423
  * fabricated answer for any of them (an empty tree, a made-up sha, a silent
3661
4424
  * no-op `checkout`) would leak into consumer logic as fact. So every
3662
4425
  * unstubbed method fails loudly as a defect
@@ -4395,7 +5158,7 @@ declare class UnsatisfiableConstraintError extends UnsatisfiableConstraintError_
4395
5158
  get message(): string;
4396
5159
  }
4397
5160
  //#endregion
4398
- //#region ../../node_modules/.pnpm/@effected+npm@0.8.2_@effected+semver@0.3.2_effect@4.0.0-beta.101__effect@4.0.0-beta.101/node_modules/@effected/npm/index.d.ts
5161
+ //#region ../../node_modules/.pnpm/@effected+npm@0.8.3_@effected+semver@0.3.2_effect@4.0.0-beta.101__effect@4.0.0-beta.101/node_modules/@effected/npm/index.d.ts
4399
5162
  //#region src/CatalogAssemblyError.d.ts
4400
5163
  declare const CatalogAssemblyError_base: Schema.Class<CatalogAssemblyError, Schema.TaggedStruct<"CatalogAssemblyError", {
4401
5164
  /**
@@ -4969,7 +5732,7 @@ declare class GlobPattern extends GlobPattern_base {
4969
5732
  static readonly FromString: Schema.Codec<GlobPattern, string>;
4970
5733
  }
4971
5734
  //#endregion
4972
- //#region ../../node_modules/.pnpm/@effected+lockfiles@0.3.2_@effected+jsonc@0.5.2_effect@4.0.0-beta.101__@effected+npm@0._ff048038a9678f5144f817ad24d8f96e/node_modules/@effected/lockfiles/index.d.ts
5735
+ //#region ../../node_modules/.pnpm/@effected+lockfiles@0.3.2_@effected+jsonc@0.5.2_effect@4.0.0-beta.101__@effected+npm@0._3c1784fba62fde9a5bac4cf15387fd04/node_modules/@effected/lockfiles/index.d.ts
4973
5736
  //#region src/BunExtension.d.ts
4974
5737
  declare const BunExtension_base: Schema.Class<BunExtension, Schema.Struct<{
4975
5738
  readonly _tag: Schema.tag<"bun">;
@@ -5981,7 +6744,7 @@ declare class Package extends Package_base {
5981
6744
  toJsonString(options?: PackageFormatOptions): string;
5982
6745
  }
5983
6746
  //#endregion
5984
- //#region ../../node_modules/.pnpm/@effected+workspaces@0.9.5_@effected+jsonc@0.5.2_effect@4.0.0-beta.101__effect@4.0.0-beta.101/node_modules/@effected/workspaces/index.d.ts
6747
+ //#region ../../node_modules/.pnpm/@effected+workspaces@0.10.2_@effected+jsonc@0.5.2_effect@4.0.0-beta.101__@effected+semv_feff9e309e6abeafa28f7ea259b8a9bf/node_modules/@effected/workspaces/index.d.ts
5985
6748
  //#region src/WorkspacePackage.d.ts
5986
6749
  declare const PublishConfig_base: Schema.Class<PublishConfig, Schema.Struct<{
5987
6750
  /** Scoped-package visibility. Its presence overrides `private`. */
@@ -6748,6 +7511,58 @@ declare class ConfigDependencyHooks extends ConfigDependencyHooks_base {
6748
7511
  * `WorkspaceCatalogs.layerWithConfigDependencies`.
6749
7512
  */
6750
7513
  static readonly layerLive: Layer.Layer<ConfigDependencyHooks>;
7514
+ /**
7515
+ * The subprocess layer: replays each config dependency's pnpmfile in a `node`
7516
+ * child process instead of an in-process dynamic `import()`, with identical
7517
+ * typed semantics to {@link ConfigDependencyHooks.layerLive} — the two are
7518
+ * drop-in interchangeable.
7519
+ *
7520
+ * @remarks
7521
+ * `layerLive` computes the `import()` path at runtime, and a bundler (rspack,
7522
+ * for one) compiles a *computed* dynamic import into a context module that
7523
+ * throws `Cannot find module 'file:///…'` at runtime — so in any bundled
7524
+ * consumer, a GitHub Action above all, the in-process replay is unreachable.
7525
+ * This layer keeps every computed load out of the bundle graph: the replay
7526
+ * program is a **static** string constant passed via argv
7527
+ * (`node --input-type=module -e <script> <root> <seed> <...names>`), and the
7528
+ * child process performs the computed imports where no bundler rewrote them.
7529
+ * A subprocess also keeps config-dependency code out of the consumer's own
7530
+ * process.
7531
+ *
7532
+ * The contract's semantics are unchanged, not the downstream fail-open shape:
7533
+ * an empty `configDependencies` returns the seed without spawning anything; a
7534
+ * `..` path segment in a dependency name fails typed **before** any spawn; a
7535
+ * missing pnpmfile (neither `.mjs` nor `.cjs`) is the one legitimate skip,
7536
+ * discriminated inside the child by `err.url` equality exactly as
7537
+ * `layerLive` discriminates in process; any other load failure — a syntax
7538
+ * error, a throwing top level, an `ERR_MODULE_NOT_FOUND` for a module the
7539
+ * pnpmfile itself imports — and a hook that throws when called are serialized
7540
+ * back per-name and surface typed as a `hooks`-source `CatalogAssemblyError`
7541
+ * naming that dependency. A hook's returned *data* stays tolerantly threaded
7542
+ * (last well-formed write wins), never fatal. Spawn and transport failures —
7543
+ * `node` absent, a non-zero exit without a result payload, unparseable
7544
+ * output — fail typed too, never a defect and never a silent skip.
7545
+ *
7546
+ * Two bounds this layer imposes that `layerLive` cannot: the replay is
7547
+ * given thirty seconds (a pnpmfile that loops or awaits forever fails typed
7548
+ * instead of hanging the memoized assemble pass — a subprocess is killable,
7549
+ * while `layerLive`'s in-process synchronous hook call is not interruptible
7550
+ * by any means, so the asymmetry is inherent, not a parity violation), and
7551
+ * the child's stdout is captured under `Run.jsonLine`'s 16 MiB default
7552
+ * ceiling (a hook that logs more than that fails typed as `tooLarge`, where
7553
+ * `layerLive` — which captures nothing — would succeed).
7554
+ *
7555
+ * Catalog folding and normalization stay in the **parent** (the same
7556
+ * `@pnpm/catalogs`-derived path `layerLive` uses); the child returns only the
7557
+ * raw threaded config slice, since the script cannot import kit code.
7558
+ *
7559
+ * Requires core's `ChildProcessSpawner`, resolved when the layer is built —
7560
+ * the consumer provides it once at the edge (`@effect/platform-node`'s
7561
+ * `NodeServices.layer`), the same discharge `@effected/git` uses. Wired by
7562
+ * `WorkspaceCatalogs.layerWithConfigDependenciesSubprocess` /
7563
+ * `Workspaces.layerWithConfigDependenciesSubprocess`.
7564
+ */
7565
+ static readonly layerSubprocess: Layer.Layer<ConfigDependencyHooks, never, ChildProcessSpawner.ChildProcessSpawner>;
6751
7566
  }
6752
7567
  declare const DetectedPackageManager_base: Schema.Class<DetectedPackageManager, Schema.Struct<{
6753
7568
  /** The detected manager. */
@@ -7480,6 +8295,24 @@ declare class WorkspaceCatalogs extends WorkspaceCatalogs_base {
7480
8295
  * Parameterized, so bind it to a `const` and reuse it.
7481
8296
  */
7482
8297
  static readonly layerWithConfigDependencies: (options?: WorkspaceCatalogsOptions) => Layer.Layer<WorkspaceCatalogs, never, WorkspaceRoot | LockfileReader | FileSystem.FileSystem | Path.Path>;
8298
+ /**
8299
+ * The opt-in layer that replays config-dependency `pnpmfile` hooks in a
8300
+ * `node` **child process**: it wires
8301
+ * {@link ConfigDependencyHooks.layerSubprocess} in place of the in-process
8302
+ * `layerLive`.
8303
+ *
8304
+ * @remarks
8305
+ * Same typed semantics as {@link WorkspaceCatalogs.layerWithConfigDependencies}
8306
+ * — the two hook layers are drop-in interchangeable — but the replay's
8307
+ * computed dynamic `import()` runs in the subprocess, so it survives bundling
8308
+ * (a bundler compiles a computed in-process `import()` into a context module
8309
+ * that cannot resolve at runtime — every bundled GitHub Action hits this).
8310
+ * The cost is one extra requirement: core's `ChildProcessSpawner`, provided
8311
+ * once at the edge (`@effect/platform-node`'s `NodeServices.layer`) — the
8312
+ * same sanctioned R-widening as `Workspaces.layerWithGit`. Parameterized, so
8313
+ * bind it to a `const` and reuse it.
8314
+ */
8315
+ static readonly layerWithConfigDependenciesSubprocess: (options?: WorkspaceCatalogsOptions) => Layer.Layer<WorkspaceCatalogs, never, WorkspaceRoot | LockfileReader | FileSystem.FileSystem | Path.Path | ChildProcessSpawner.ChildProcessSpawner>;
7483
8316
  /**
7484
8317
  * A test double satisfying the full {@link WorkspaceCatalogsShape} with no
7485
8318
  * filesystem, lockfile read, or hook replay.