@paraharness/git 0.0.0-stage → 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +68 -2
- package/dist/builders/create-git-candidate-comparison-tools.d.ts +13 -0
- package/dist/builders/create-git-candidate-comparison-tools.d.ts.map +1 -0
- package/dist/builders/create-git-candidate-comparison-tools.js +41 -0
- package/dist/builders/create-git-candidate-comparison-tools.js.map +1 -0
- package/dist/builders/create-git-commit-and-push-builder.d.ts +18 -0
- package/dist/builders/create-git-commit-and-push-builder.d.ts.map +1 -0
- package/dist/builders/create-git-commit-and-push-builder.js +65 -0
- package/dist/builders/create-git-commit-and-push-builder.js.map +1 -0
- package/dist/builders/create-git-cow-worktree-builder.d.ts +15 -0
- package/dist/builders/create-git-cow-worktree-builder.d.ts.map +1 -0
- package/dist/builders/create-git-cow-worktree-builder.js +64 -0
- package/dist/builders/create-git-cow-worktree-builder.js.map +1 -0
- package/dist/builders/create-git-discard-branch-builder.d.ts +13 -0
- package/dist/builders/create-git-discard-branch-builder.d.ts.map +1 -0
- package/dist/builders/create-git-discard-branch-builder.js +22 -0
- package/dist/builders/create-git-discard-branch-builder.js.map +1 -0
- package/dist/builders/create-git-keep-worktree-builder.d.ts +13 -0
- package/dist/builders/create-git-keep-worktree-builder.d.ts.map +1 -0
- package/dist/builders/create-git-keep-worktree-builder.js +22 -0
- package/dist/builders/create-git-keep-worktree-builder.js.map +1 -0
- package/dist/builders/create-git-merge-queue-builder.d.ts +19 -0
- package/dist/builders/create-git-merge-queue-builder.d.ts.map +1 -0
- package/dist/builders/create-git-merge-queue-builder.js +59 -0
- package/dist/builders/create-git-merge-queue-builder.js.map +1 -0
- package/dist/builders/create-git-patch-equivalence-builder.d.ts +13 -0
- package/dist/builders/create-git-patch-equivalence-builder.d.ts.map +1 -0
- package/dist/builders/create-git-patch-equivalence-builder.js +32 -0
- package/dist/builders/create-git-patch-equivalence-builder.js.map +1 -0
- package/dist/builders/create-git-public-surface-cross-tester-builder.d.ts +14 -0
- package/dist/builders/create-git-public-surface-cross-tester-builder.d.ts.map +1 -0
- package/dist/builders/create-git-public-surface-cross-tester-builder.js +36 -0
- package/dist/builders/create-git-public-surface-cross-tester-builder.js.map +1 -0
- package/dist/builders/create-git-ref-reader-tools.d.ts +13 -0
- package/dist/builders/create-git-ref-reader-tools.d.ts.map +1 -0
- package/dist/builders/create-git-ref-reader-tools.js +41 -0
- package/dist/builders/create-git-ref-reader-tools.js.map +1 -0
- package/dist/builders/create-git-reset-worktree-builder.d.ts +13 -0
- package/dist/builders/create-git-reset-worktree-builder.d.ts.map +1 -0
- package/dist/builders/create-git-reset-worktree-builder.js +22 -0
- package/dist/builders/create-git-reset-worktree-builder.js.map +1 -0
- package/dist/builders/create-git-snapshot-and-reset-builder.d.ts +13 -0
- package/dist/builders/create-git-snapshot-and-reset-builder.d.ts.map +1 -0
- package/dist/builders/create-git-snapshot-and-reset-builder.js +23 -0
- package/dist/builders/create-git-snapshot-and-reset-builder.js.map +1 -0
- package/dist/builders/git-commit-and-push-builder.d.ts +44 -0
- package/dist/builders/git-commit-and-push-builder.d.ts.map +1 -0
- package/dist/builders/git-commit-and-push-builder.js +2 -0
- package/dist/builders/git-commit-and-push-builder.js.map +1 -0
- package/dist/builders/git-commit-and-push-options.d.ts +22 -0
- package/dist/builders/git-commit-and-push-options.d.ts.map +1 -0
- package/dist/builders/git-commit-and-push-options.js +2 -0
- package/dist/builders/git-commit-and-push-options.js.map +1 -0
- package/dist/builders/git-cow-worktree-builder.d.ts +64 -0
- package/dist/builders/git-cow-worktree-builder.d.ts.map +1 -0
- package/dist/builders/git-cow-worktree-builder.js +2 -0
- package/dist/builders/git-cow-worktree-builder.js.map +1 -0
- package/dist/builders/git-cow-worktree-options.d.ts +42 -0
- package/dist/builders/git-cow-worktree-options.d.ts.map +1 -0
- package/dist/builders/git-cow-worktree-options.js +2 -0
- package/dist/builders/git-cow-worktree-options.js.map +1 -0
- package/dist/builders/git-merge-queue-builder.d.ts +37 -0
- package/dist/builders/git-merge-queue-builder.d.ts.map +1 -0
- package/dist/builders/git-merge-queue-builder.js +2 -0
- package/dist/builders/git-merge-queue-builder.js.map +1 -0
- package/dist/builders/git-merge-queue-options.d.ts +23 -0
- package/dist/builders/git-merge-queue-options.d.ts.map +1 -0
- package/dist/builders/git-merge-queue-options.js +2 -0
- package/dist/builders/git-merge-queue-options.js.map +1 -0
- package/dist/builders/git-namespace-contract.d.ts +141 -0
- package/dist/builders/git-namespace-contract.d.ts.map +1 -0
- package/dist/builders/git-namespace-contract.js +2 -0
- package/dist/builders/git-namespace-contract.js.map +1 -0
- package/dist/builders/git-namespace.d.ts +6 -0
- package/dist/builders/git-namespace.d.ts.map +1 -0
- package/dist/builders/git-namespace.js +32 -0
- package/dist/builders/git-namespace.js.map +1 -0
- package/dist/builders/git-public-surface-cross-tester-options.d.ts +16 -0
- package/dist/builders/git-public-surface-cross-tester-options.d.ts.map +1 -0
- package/dist/builders/git-public-surface-cross-tester-options.js +2 -0
- package/dist/builders/git-public-surface-cross-tester-options.js.map +1 -0
- package/dist/builders/git-reconcile-strategy-options.d.ts +16 -0
- package/dist/builders/git-reconcile-strategy-options.d.ts.map +1 -0
- package/dist/builders/git-reconcile-strategy-options.js +2 -0
- package/dist/builders/git-reconcile-strategy-options.js.map +1 -0
- package/dist/builders/internal/build-git-cow-worktree-node.d.ts +35 -0
- package/dist/builders/internal/build-git-cow-worktree-node.d.ts.map +1 -0
- package/dist/builders/internal/build-git-cow-worktree-node.js +77 -0
- package/dist/builders/internal/build-git-cow-worktree-node.js.map +1 -0
- package/dist/executors/create-git-executors.d.ts +12 -0
- package/dist/executors/create-git-executors.d.ts.map +1 -0
- package/dist/executors/create-git-executors.js +43 -0
- package/dist/executors/create-git-executors.js.map +1 -0
- package/dist/executors/git-checkpoint-payload.d.ts +44 -0
- package/dist/executors/git-checkpoint-payload.d.ts.map +1 -0
- package/dist/executors/git-checkpoint-payload.js +2 -0
- package/dist/executors/git-checkpoint-payload.js.map +1 -0
- package/dist/executors/git-commit-and-merge-steps.d.ts +33 -0
- package/dist/executors/git-commit-and-merge-steps.d.ts.map +1 -0
- package/dist/executors/git-commit-and-merge-steps.js +52 -0
- package/dist/executors/git-commit-and-merge-steps.js.map +1 -0
- package/dist/executors/git-cow-worktree-scope.d.ts +201 -0
- package/dist/executors/git-cow-worktree-scope.d.ts.map +1 -0
- package/dist/executors/git-cow-worktree-scope.js +260 -0
- package/dist/executors/git-cow-worktree-scope.js.map +1 -0
- package/dist/executors/git-cross-verifiers-and-tools.d.ts +42 -0
- package/dist/executors/git-cross-verifiers-and-tools.d.ts.map +1 -0
- package/dist/executors/git-cross-verifiers-and-tools.js +112 -0
- package/dist/executors/git-cross-verifiers-and-tools.js.map +1 -0
- package/dist/executors/git-executors.constants.d.ts +4 -0
- package/dist/executors/git-executors.constants.d.ts.map +1 -0
- package/dist/executors/git-executors.constants.js +4 -0
- package/dist/executors/git-executors.constants.js.map +1 -0
- package/dist/executors/git-hooks-and-checks.d.ts +51 -0
- package/dist/executors/git-hooks-and-checks.d.ts.map +1 -0
- package/dist/executors/git-hooks-and-checks.js +139 -0
- package/dist/executors/git-hooks-and-checks.js.map +1 -0
- package/dist/executors/internal/checkpoint-restore-steps.d.ts +50 -0
- package/dist/executors/internal/checkpoint-restore-steps.d.ts.map +1 -0
- package/dist/executors/internal/checkpoint-restore-steps.js +184 -0
- package/dist/executors/internal/checkpoint-restore-steps.js.map +1 -0
- package/dist/executors/internal/checkpoint-staging-and-integrity.d.ts +51 -0
- package/dist/executors/internal/checkpoint-staging-and-integrity.d.ts.map +1 -0
- package/dist/executors/internal/checkpoint-staging-and-integrity.js +192 -0
- package/dist/executors/internal/checkpoint-staging-and-integrity.js.map +1 -0
- package/dist/executors/internal/compute-worktree-status-options.d.ts +15 -0
- package/dist/executors/internal/compute-worktree-status-options.d.ts.map +1 -0
- package/dist/executors/internal/compute-worktree-status-options.js +2 -0
- package/dist/executors/internal/compute-worktree-status-options.js.map +1 -0
- package/dist/executors/internal/cow-worktree-hydrator.d.ts +51 -0
- package/dist/executors/internal/cow-worktree-hydrator.d.ts.map +1 -0
- package/dist/executors/internal/cow-worktree-hydrator.js +174 -0
- package/dist/executors/internal/cow-worktree-hydrator.js.map +1 -0
- package/dist/executors/internal/file-digest-and-globs.d.ts +58 -0
- package/dist/executors/internal/file-digest-and-globs.d.ts.map +1 -0
- package/dist/executors/internal/file-digest-and-globs.js +188 -0
- package/dist/executors/internal/file-digest-and-globs.js.map +1 -0
- package/dist/executors/internal/git-checkpoint-diff-effects.d.ts +16 -0
- package/dist/executors/internal/git-checkpoint-diff-effects.d.ts.map +1 -0
- package/dist/executors/internal/git-checkpoint-diff-effects.js +38 -0
- package/dist/executors/internal/git-checkpoint-diff-effects.js.map +1 -0
- package/dist/executors/internal/git-checkpoint-restore.d.ts +14 -0
- package/dist/executors/internal/git-checkpoint-restore.d.ts.map +1 -0
- package/dist/executors/internal/git-checkpoint-restore.js +37 -0
- package/dist/executors/internal/git-checkpoint-restore.js.map +1 -0
- package/dist/executors/internal/git-checkpoint-serialize.d.ts +13 -0
- package/dist/executors/internal/git-checkpoint-serialize.d.ts.map +1 -0
- package/dist/executors/internal/git-checkpoint-serialize.js +48 -0
- package/dist/executors/internal/git-checkpoint-serialize.js.map +1 -0
- package/dist/executors/internal/git-checkpoint-status-map.d.ts +14 -0
- package/dist/executors/internal/git-checkpoint-status-map.d.ts.map +1 -0
- package/dist/executors/internal/git-checkpoint-status-map.js +27 -0
- package/dist/executors/internal/git-checkpoint-status-map.js.map +1 -0
- package/dist/executors/internal/git-cli-command-options.d.ts +21 -0
- package/dist/executors/internal/git-cli-command-options.d.ts.map +1 -0
- package/dist/executors/internal/git-cli-command-options.js +2 -0
- package/dist/executors/internal/git-cli-command-options.js.map +1 -0
- package/dist/executors/internal/git-cli-command-result.d.ts +16 -0
- package/dist/executors/internal/git-cli-command-result.d.ts.map +1 -0
- package/dist/executors/internal/git-cli-command-result.js +2 -0
- package/dist/executors/internal/git-cli-command-result.js.map +1 -0
- package/dist/executors/internal/git-cli-runner.d.ts +73 -0
- package/dist/executors/internal/git-cli-runner.d.ts.map +1 -0
- package/dist/executors/internal/git-cli-runner.js +157 -0
- package/dist/executors/internal/git-cli-runner.js.map +1 -0
- package/dist/executors/internal/git-cross-test-import-scanner.d.ts +68 -0
- package/dist/executors/internal/git-cross-test-import-scanner.d.ts.map +1 -0
- package/dist/executors/internal/git-cross-test-import-scanner.js +226 -0
- package/dist/executors/internal/git-cross-test-import-scanner.js.map +1 -0
- package/dist/executors/internal/git-executor.constants.d.ts +29 -0
- package/dist/executors/internal/git-executor.constants.d.ts.map +1 -0
- package/dist/executors/internal/git-executor.constants.js +40 -0
- package/dist/executors/internal/git-executor.constants.js.map +1 -0
- package/dist/executors/internal/git-merge-train-bisect.d.ts +51 -0
- package/dist/executors/internal/git-merge-train-bisect.d.ts.map +1 -0
- package/dist/executors/internal/git-merge-train-bisect.js +152 -0
- package/dist/executors/internal/git-merge-train-bisect.js.map +1 -0
- package/dist/executors/internal/git-tool-dispatchers.d.ts +26 -0
- package/dist/executors/internal/git-tool-dispatchers.d.ts.map +1 -0
- package/dist/executors/internal/git-tool-dispatchers.js +174 -0
- package/dist/executors/internal/git-tool-dispatchers.js.map +1 -0
- package/dist/executors/internal/git-worktree-acquire-root.d.ts +22 -0
- package/dist/executors/internal/git-worktree-acquire-root.d.ts.map +1 -0
- package/dist/executors/internal/git-worktree-acquire-root.js +67 -0
- package/dist/executors/internal/git-worktree-acquire-root.js.map +1 -0
- package/dist/executors/internal/git-worktree-commit-child.d.ts +26 -0
- package/dist/executors/internal/git-worktree-commit-child.d.ts.map +1 -0
- package/dist/executors/internal/git-worktree-commit-child.js +88 -0
- package/dist/executors/internal/git-worktree-commit-child.js.map +1 -0
- package/dist/executors/internal/git-worktree-flush-and-prune.d.ts +43 -0
- package/dist/executors/internal/git-worktree-flush-and-prune.d.ts.map +1 -0
- package/dist/executors/internal/git-worktree-flush-and-prune.js +169 -0
- package/dist/executors/internal/git-worktree-flush-and-prune.js.map +1 -0
- package/dist/executors/internal/git-worktree-fork-and-release.d.ts +37 -0
- package/dist/executors/internal/git-worktree-fork-and-release.d.ts.map +1 -0
- package/dist/executors/internal/git-worktree-fork-and-release.js +159 -0
- package/dist/executors/internal/git-worktree-fork-and-release.js.map +1 -0
- package/dist/executors/internal/git-worktree-materialize-merge.d.ts +51 -0
- package/dist/executors/internal/git-worktree-materialize-merge.d.ts.map +1 -0
- package/dist/executors/internal/git-worktree-materialize-merge.js +161 -0
- package/dist/executors/internal/git-worktree-materialize-merge.js.map +1 -0
- package/dist/executors/internal/git-worktree-reattach.d.ts +57 -0
- package/dist/executors/internal/git-worktree-reattach.d.ts.map +1 -0
- package/dist/executors/internal/git-worktree-reattach.js +324 -0
- package/dist/executors/internal/git-worktree-reattach.js.map +1 -0
- package/dist/executors/internal/git-worktree-sync-child-and-root.d.ts +26 -0
- package/dist/executors/internal/git-worktree-sync-child-and-root.d.ts.map +1 -0
- package/dist/executors/internal/git-worktree-sync-child-and-root.js +82 -0
- package/dist/executors/internal/git-worktree-sync-child-and-root.js.map +1 -0
- package/dist/executors/internal/host-repository-head-state.d.ts +10 -0
- package/dist/executors/internal/host-repository-head-state.d.ts.map +1 -0
- package/dist/executors/internal/host-repository-head-state.js +2 -0
- package/dist/executors/internal/host-repository-head-state.js.map +1 -0
- package/dist/executors/internal/merge-train-candidate.d.ts +14 -0
- package/dist/executors/internal/merge-train-candidate.d.ts.map +1 -0
- package/dist/executors/internal/merge-train-candidate.js +2 -0
- package/dist/executors/internal/merge-train-candidate.js.map +1 -0
- package/dist/executors/internal/merge-train-chain-entry.d.ts +13 -0
- package/dist/executors/internal/merge-train-chain-entry.d.ts.map +1 -0
- package/dist/executors/internal/merge-train-chain-entry.js +2 -0
- package/dist/executors/internal/merge-train-chain-entry.js.map +1 -0
- package/dist/executors/internal/merge-train-result.d.ts +19 -0
- package/dist/executors/internal/merge-train-result.d.ts.map +1 -0
- package/dist/executors/internal/merge-train-result.js +2 -0
- package/dist/executors/internal/merge-train-result.js.map +1 -0
- package/dist/executors/internal/merge-train-runner.d.ts +16 -0
- package/dist/executors/internal/merge-train-runner.d.ts.map +1 -0
- package/dist/executors/internal/merge-train-runner.js +141 -0
- package/dist/executors/internal/merge-train-runner.js.map +1 -0
- package/dist/executors/internal/merge-tree-materializer-params.d.ts +19 -0
- package/dist/executors/internal/merge-tree-materializer-params.d.ts.map +1 -0
- package/dist/executors/internal/merge-tree-materializer-params.js +2 -0
- package/dist/executors/internal/merge-tree-materializer-params.js.map +1 -0
- package/dist/executors/internal/parent-fast-forward.d.ts +47 -0
- package/dist/executors/internal/parent-fast-forward.d.ts.map +1 -0
- package/dist/executors/internal/parent-fast-forward.js +138 -0
- package/dist/executors/internal/parent-fast-forward.js.map +1 -0
- package/dist/executors/internal/porcelain-v2-parser.d.ts +49 -0
- package/dist/executors/internal/porcelain-v2-parser.d.ts.map +1 -0
- package/dist/executors/internal/porcelain-v2-parser.js +165 -0
- package/dist/executors/internal/porcelain-v2-parser.js.map +1 -0
- package/dist/executors/internal/resolve-effective-base-branch.d.ts +13 -0
- package/dist/executors/internal/resolve-effective-base-branch.d.ts.map +1 -0
- package/dist/executors/internal/resolve-effective-base-branch.js +38 -0
- package/dist/executors/internal/resolve-effective-base-branch.js.map +1 -0
- package/dist/executors/internal/squash-rebase-and-push.d.ts +14 -0
- package/dist/executors/internal/squash-rebase-and-push.d.ts.map +1 -0
- package/dist/executors/internal/squash-rebase-and-push.js +192 -0
- package/dist/executors/internal/squash-rebase-and-push.js.map +1 -0
- package/dist/executors/internal/staged-checkpoint-tree-result.d.ts +13 -0
- package/dist/executors/internal/staged-checkpoint-tree-result.d.ts.map +1 -0
- package/dist/executors/internal/staged-checkpoint-tree-result.js +2 -0
- package/dist/executors/internal/staged-checkpoint-tree-result.js.map +1 -0
- package/dist/executors/internal/stateless-merge-tree-result.d.ts +12 -0
- package/dist/executors/internal/stateless-merge-tree-result.d.ts.map +1 -0
- package/dist/executors/internal/stateless-merge-tree-result.js +2 -0
- package/dist/executors/internal/stateless-merge-tree-result.js.map +1 -0
- package/dist/executors/internal/synthesized-working-tree-commit.d.ts +10 -0
- package/dist/executors/internal/synthesized-working-tree-commit.d.ts.map +1 -0
- package/dist/executors/internal/synthesized-working-tree-commit.js +2 -0
- package/dist/executors/internal/synthesized-working-tree-commit.js.map +1 -0
- package/dist/executors/internal/worktree-integrity-verdict.d.ts +10 -0
- package/dist/executors/internal/worktree-integrity-verdict.d.ts.map +1 -0
- package/dist/executors/internal/worktree-integrity-verdict.js +2 -0
- package/dist/executors/internal/worktree-integrity-verdict.js.map +1 -0
- package/dist/executors/internal/worktree-status-snapshot.d.ts +17 -0
- package/dist/executors/internal/worktree-status-snapshot.d.ts.map +1 -0
- package/dist/executors/internal/worktree-status-snapshot.js +2 -0
- package/dist/executors/internal/worktree-status-snapshot.js.map +1 -0
- package/dist/index.d.ts +31 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +20 -0
- package/dist/index.js.map +1 -0
- package/dist/schemas/git-receipts.schema.d.ts +174 -0
- package/dist/schemas/git-receipts.schema.d.ts.map +1 -0
- package/dist/schemas/git-receipts.schema.js +123 -0
- package/dist/schemas/git-receipts.schema.js.map +1 -0
- package/package.json +71 -3
|
@@ -0,0 +1,141 @@
|
|
|
1
|
+
import type { AstBuilder, CrossVerifierBuilder, GitCandidateComparisonToolNode, GitDiscardBranchNode, GitKeepWorktreeNode, GitPatchEquivalenceNode, GitPublicSurfaceCrossTesterNode, GitRefReaderToolNode, GitScopeReceipt, GitSnapshotAndResetNode, GitWorktreeHandle, MaybeBuilder, NodeRunnerNode } from '@paraharness/core';
|
|
2
|
+
import type { GitAbortMetaSchema, GitScopeReceiptSchema, GitSyncReceiptSchema } from '../schemas/git-receipts.schema.js';
|
|
3
|
+
import type { GitCommitAndPushBuilder } from './git-commit-and-push-builder.js';
|
|
4
|
+
import type { GitCommitAndPushOptions } from './git-commit-and-push-options.js';
|
|
5
|
+
import type { GitCowWorktreeBuilder } from './git-cow-worktree-builder.js';
|
|
6
|
+
import type { GitCowWorktreeOptions } from './git-cow-worktree-options.js';
|
|
7
|
+
import type { GitMergeQueueBuilder } from './git-merge-queue-builder.js';
|
|
8
|
+
import type { GitMergeQueueOptions } from './git-merge-queue-options.js';
|
|
9
|
+
import type { GitPublicSurfaceCrossTesterOptions } from './git-public-surface-cross-tester-options.js';
|
|
10
|
+
/**
|
|
11
|
+
* Public `git` builder and schema namespace contract (`import { git } from '@paraharness/git'`).
|
|
12
|
+
*
|
|
13
|
+
* Mounts `ScopeReceiptSchema`, `SyncReceiptSchema`, `AbortMetaSchema`, and all declarative
|
|
14
|
+
* Copy-on-Write worktree, hook, cross-verifier, tool, and delivery step builders.
|
|
15
|
+
*/
|
|
16
|
+
export interface GitNamespace {
|
|
17
|
+
/** Zod schema validating `GitScopeReceipt` objects returned by `inspect()` and `commitChild()`. */
|
|
18
|
+
readonly ScopeReceiptSchema: typeof GitScopeReceiptSchema;
|
|
19
|
+
/** Zod schema validating `GitSyncReceipt` objects returned by `syncChild()` and `syncRoot()`. */
|
|
20
|
+
readonly SyncReceiptSchema: typeof GitSyncReceiptSchema;
|
|
21
|
+
/** Zod schema validating `GitAbortMeta` objects returned by `git.snapshotAndReset()`. */
|
|
22
|
+
readonly AbortMetaSchema: typeof GitAbortMetaSchema;
|
|
23
|
+
/**
|
|
24
|
+
* Creates a fluent builder for a Tier-3 branchable Copy-on-Write Git worktree scope.
|
|
25
|
+
*
|
|
26
|
+
* Provisions disjoint sibling `<dir>/roots/<runId>` and `<dir>/forks/<runId>/<forkId>` worktrees at runtime.
|
|
27
|
+
*
|
|
28
|
+
* @param {GitCowWorktreeOptions} options - Host repository path and worktree base directory.
|
|
29
|
+
*
|
|
30
|
+
* @returns {GitCowWorktreeBuilder} Immutable fluent worktree scope builder.
|
|
31
|
+
*/
|
|
32
|
+
cowWorktree(options: GitCowWorktreeOptions): GitCowWorktreeBuilder;
|
|
33
|
+
/**
|
|
34
|
+
* Creates a fluent builder for a retry-safe squash, rebase, verify, and push step.
|
|
35
|
+
*
|
|
36
|
+
* Compiles into a passive `GitCommitAndPushNode<TIn>` dispatched via `RuntimeExecutorRegistry.steps`.
|
|
37
|
+
*
|
|
38
|
+
* @template TIn Step input payload type.
|
|
39
|
+
*
|
|
40
|
+
* @param {string} id - Unique step node identifier.
|
|
41
|
+
* @param {GitCommitAndPushOptions<TIn>} options - Remote branch and commit message projections.
|
|
42
|
+
*
|
|
43
|
+
* @returns {GitCommitAndPushBuilder<TIn>} Immutable fluent commit-and-push step builder.
|
|
44
|
+
*/
|
|
45
|
+
commitAndPush<TIn = unknown>(id: string, options: GitCommitAndPushOptions<TIn>): GitCommitAndPushBuilder<TIn>;
|
|
46
|
+
/**
|
|
47
|
+
* Creates a fluent builder for a cumulative batch merge-train verification step.
|
|
48
|
+
*
|
|
49
|
+
* Constructs a speculative rebase chain $R_1 \dots R_k$ up to `maxBatchSize` and binary-bisects on failure.
|
|
50
|
+
*
|
|
51
|
+
* @template TIn Validated step input type.
|
|
52
|
+
* @template TOut Validated step output type.
|
|
53
|
+
*
|
|
54
|
+
* @param {string} id - Unique merge queue step identifier.
|
|
55
|
+
* @param {GitMergeQueueOptions<TIn, TOut>} options - Target branch, batch size, and verification check.
|
|
56
|
+
*
|
|
57
|
+
* @returns {GitMergeQueueBuilder<TIn, TOut>} Immutable fluent merge queue step builder.
|
|
58
|
+
*/
|
|
59
|
+
mergeQueue<TIn = unknown, TOut = unknown>(id: string, options: GitMergeQueueOptions<TIn, TOut>): GitMergeQueueBuilder<TIn, TOut>;
|
|
60
|
+
/**
|
|
61
|
+
* Creates an idempotent abort hook builder snapshotting the dirty worktree to `refs/harness/aborted/<run-id>/<stepExecId>`.
|
|
62
|
+
*
|
|
63
|
+
* Resets the working tree to `handle.baseRef` and clears `unresolvedConflictPaths` after snapshotting.
|
|
64
|
+
*
|
|
65
|
+
* @param {string} [id] - Optional custom abort hook identifier.
|
|
66
|
+
*
|
|
67
|
+
* @returns {AstBuilder<GitSnapshotAndResetNode>} Immutable abort hook builder.
|
|
68
|
+
*/
|
|
69
|
+
snapshotAndReset(id?: string): AstBuilder<GitSnapshotAndResetNode>;
|
|
70
|
+
/**
|
|
71
|
+
* Creates a rewind hook builder preserving the active worktree and topology overlay in-place (`resetsRunOverlay: false`).
|
|
72
|
+
*
|
|
73
|
+
* Used with `.rewindTo(stepId, { onRewind: git.keepWorktree() })` for live steering without discarding work.
|
|
74
|
+
*
|
|
75
|
+
* @param {string} [id] - Optional custom rewind hook identifier.
|
|
76
|
+
*
|
|
77
|
+
* @returns {AstBuilder<GitKeepWorktreeNode>} Immutable rewind hook builder.
|
|
78
|
+
*/
|
|
79
|
+
keepWorktree(id?: string): AstBuilder<GitKeepWorktreeNode>;
|
|
80
|
+
/**
|
|
81
|
+
* Creates a rewind hook builder resetting the worktree to `targetStepBaseScopeCheckpoint` (`resetsRunOverlay: true`).
|
|
82
|
+
*
|
|
83
|
+
* Restores both the physical working tree and the run's Copy-on-Write topology overlay to the target step entry.
|
|
84
|
+
*
|
|
85
|
+
* @param {string} [id] - Optional custom rewind hook identifier.
|
|
86
|
+
*
|
|
87
|
+
* @returns {AstBuilder<GitDiscardBranchNode>} Immutable rewind hook builder.
|
|
88
|
+
*/
|
|
89
|
+
resetWorktree(id?: string): AstBuilder<GitDiscardBranchNode>;
|
|
90
|
+
/**
|
|
91
|
+
* Alias for `git.resetWorktree()` compiling to `GitDiscardBranchNode` (`resetsRunOverlay: true`).
|
|
92
|
+
*
|
|
93
|
+
* Restores the worktree to `targetStepBaseScopeCheckpoint` and discards uncommitted overlay mutations.
|
|
94
|
+
*
|
|
95
|
+
* @param {string} [id] - Optional custom rewind hook identifier.
|
|
96
|
+
*
|
|
97
|
+
* @returns {AstBuilder<GitDiscardBranchNode>} Immutable rewind hook builder.
|
|
98
|
+
*/
|
|
99
|
+
discardBranch(id?: string): AstBuilder<GitDiscardBranchNode>;
|
|
100
|
+
/**
|
|
101
|
+
* Creates a `CrossVerifierBuilder` transplanting boundary-only tests across speculative worktree candidates.
|
|
102
|
+
*
|
|
103
|
+
* Parses test imports against `partitionMap.partitions[*].boundaryGlobs` and cross-executes eligible tests.
|
|
104
|
+
*
|
|
105
|
+
* @param {GitPublicSurfaceCrossTesterOptions} options - Subprocess runner and partition map configuration.
|
|
106
|
+
*
|
|
107
|
+
* @returns {CrossVerifierBuilder<GitWorktreeHandle, GitScopeReceipt, Record<string, unknown>, GitPublicSurfaceCrossTesterNode>} Immutable cross-verifier builder.
|
|
108
|
+
*/
|
|
109
|
+
publicSurfaceCrossTester(options: GitPublicSurfaceCrossTesterOptions): CrossVerifierBuilder<GitWorktreeHandle, GitScopeReceipt, Record<string, unknown>, GitPublicSurfaceCrossTesterNode>;
|
|
110
|
+
/**
|
|
111
|
+
* Creates a `CrossVerifierBuilder` grouping speculative candidates by normalized patch equivalence.
|
|
112
|
+
*
|
|
113
|
+
* Computes canonicalized patch digests and equivalence classes across surviving tournament branches.
|
|
114
|
+
*
|
|
115
|
+
* @param {string} [id] - Optional custom cross-verifier identifier.
|
|
116
|
+
*
|
|
117
|
+
* @returns {CrossVerifierBuilder<GitWorktreeHandle, GitScopeReceipt, Record<string, unknown>, GitPatchEquivalenceNode>} Immutable cross-verifier builder.
|
|
118
|
+
*/
|
|
119
|
+
patchEquivalence(id?: string): CrossVerifierBuilder<GitWorktreeHandle, GitScopeReceipt, Record<string, unknown>, GitPatchEquivalenceNode>;
|
|
120
|
+
/**
|
|
121
|
+
* Creates the read-only git ref inspection tool bundle (`readRefFile`, `diffRefs`, `listRefFiles`).
|
|
122
|
+
*
|
|
123
|
+
* Enables actors to inspect `refs/harness/aborted/<run-id>/<stepExecId>` snapshots against the object store.
|
|
124
|
+
*
|
|
125
|
+
* @param {MaybeBuilder<NodeRunnerNode>} runner - Subprocess runner pool governing git command slots.
|
|
126
|
+
*
|
|
127
|
+
* @returns {readonly GitRefReaderToolNode<GitWorktreeHandle>[]} Frozen tuple of ref reader tool AST nodes.
|
|
128
|
+
*/
|
|
129
|
+
refReaderTools(runner: MaybeBuilder<NodeRunnerNode>): readonly GitRefReaderToolNode<GitWorktreeHandle>[];
|
|
130
|
+
/**
|
|
131
|
+
* Creates the speculative candidate comparison tool bundle (`diffCandidates`, `readCandidateFile`, `evalInCandidates`).
|
|
132
|
+
*
|
|
133
|
+
* Enables `candidateArbiter` and `.refineWinnerWhen()` to compare candidate refs and run sandboxed benchmarks.
|
|
134
|
+
*
|
|
135
|
+
* @param {MaybeBuilder<NodeRunnerNode>} runner - Subprocess runner pool governing git and benchmark command slots.
|
|
136
|
+
*
|
|
137
|
+
* @returns {readonly GitCandidateComparisonToolNode<GitWorktreeHandle>[]} Frozen tuple of candidate comparison tool AST nodes.
|
|
138
|
+
*/
|
|
139
|
+
candidateComparisonTools(runner: MaybeBuilder<NodeRunnerNode>): readonly GitCandidateComparisonToolNode<GitWorktreeHandle>[];
|
|
140
|
+
}
|
|
141
|
+
//# sourceMappingURL=git-namespace-contract.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"git-namespace-contract.d.ts","sourceRoot":"","sources":["../../src/builders/git-namespace-contract.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,UAAU,EACV,oBAAoB,EACpB,8BAA8B,EAC9B,oBAAoB,EACpB,mBAAmB,EACnB,uBAAuB,EACvB,+BAA+B,EAC/B,oBAAoB,EACpB,eAAe,EACf,uBAAuB,EACvB,iBAAiB,EACjB,YAAY,EACZ,cAAc,EACf,MAAM,mBAAmB,CAAC;AAC3B,OAAO,KAAK,EACV,kBAAkB,EAClB,qBAAqB,EACrB,oBAAoB,EACrB,MAAM,mCAAmC,CAAC;AAC3C,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,kCAAkC,CAAC;AAChF,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,kCAAkC,CAAC;AA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,aAAa,CAAC,EAAE,CAAC,EAAE,MAAM,GAAG,UAAU,CAAC,oBAAoB,CAAC,CAAC;IAE7D;;;;;;;;OAQG;IACH,aAAa,CAAC,EAAE,CAAC,EAAE,MAAM,GAAG,UAAU,CAAC,oBAAoB,CAAC,CAAC;IAE7D;;;;;;;;OAQG;IACH,wBAAwB,CACtB,OAAO,EAAE,kCAAkC,GAC1C,oBAAoB,CACrB,iBAAiB,EACjB,eAAe,EACf,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EACvB,+BAA+B,CAChC,CAAC;IAEF;;;;;;;;OAQG;IACH,gBAAgB,CACd,EAAE,CAAC,EAAE,MAAM,GACV,oBAAoB,CACrB,iBAAiB,EACjB,eAAe,EACf,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EACvB,uBAAuB,CACxB,CAAC;IAEF;;;;;;;;OAQG;IACH,cAAc,CACZ,MAAM,EAAE,YAAY,CAAC,cAAc,CAAC,GACnC,SAAS,oBAAoB,CAAC,iBAAiB,CAAC,EAAE,CAAC;IAEtD;;;;;;;;OAQG;IACH,wBAAwB,CACtB,MAAM,EAAE,YAAY,CAAC,cAAc,CAAC,GACnC,SAAS,8BAA8B,CAAC,iBAAiB,CAAC,EAAE,CAAC;CACjE"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"git-namespace-contract.js","sourceRoot":"","sources":["../../src/builders/git-namespace-contract.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"git-namespace.d.ts","sourceRoot":"","sources":["../../src/builders/git-namespace.ts"],"names":[],"mappings":"AAgBA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,6BAA6B,CAAC;AAEhE;;GAEG;AACH,eAAO,MAAM,GAAG,EAAE,YAehB,CAAC"}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { GitAbortMetaSchema, GitScopeReceiptSchema, GitSyncReceiptSchema, } from '../schemas/git-receipts.schema.js';
|
|
2
|
+
import { createGitCandidateComparisonTools } from './create-git-candidate-comparison-tools.js';
|
|
3
|
+
import { createGitCommitAndPushBuilder } from './create-git-commit-and-push-builder.js';
|
|
4
|
+
import { createGitCowWorktreeBuilder } from './create-git-cow-worktree-builder.js';
|
|
5
|
+
import { createGitDiscardBranchBuilder } from './create-git-discard-branch-builder.js';
|
|
6
|
+
import { createGitKeepWorktreeBuilder } from './create-git-keep-worktree-builder.js';
|
|
7
|
+
import { createGitMergeQueueBuilder } from './create-git-merge-queue-builder.js';
|
|
8
|
+
import { createGitPatchEquivalenceBuilder } from './create-git-patch-equivalence-builder.js';
|
|
9
|
+
import { createGitPublicSurfaceCrossTesterBuilder } from './create-git-public-surface-cross-tester-builder.js';
|
|
10
|
+
import { createGitRefReaderTools } from './create-git-ref-reader-tools.js';
|
|
11
|
+
import { createGitResetWorktreeBuilder } from './create-git-reset-worktree-builder.js';
|
|
12
|
+
import { createGitSnapshotAndResetBuilder } from './create-git-snapshot-and-reset-builder.js';
|
|
13
|
+
/**
|
|
14
|
+
* Frozen `git` DSL builder and receipt schema namespace (`@paraharness/git`).
|
|
15
|
+
*/
|
|
16
|
+
export const git = Object.freeze({
|
|
17
|
+
ScopeReceiptSchema: GitScopeReceiptSchema,
|
|
18
|
+
SyncReceiptSchema: GitSyncReceiptSchema,
|
|
19
|
+
AbortMetaSchema: GitAbortMetaSchema,
|
|
20
|
+
cowWorktree: createGitCowWorktreeBuilder,
|
|
21
|
+
commitAndPush: createGitCommitAndPushBuilder,
|
|
22
|
+
mergeQueue: createGitMergeQueueBuilder,
|
|
23
|
+
snapshotAndReset: createGitSnapshotAndResetBuilder,
|
|
24
|
+
keepWorktree: createGitKeepWorktreeBuilder,
|
|
25
|
+
resetWorktree: createGitResetWorktreeBuilder,
|
|
26
|
+
discardBranch: createGitDiscardBranchBuilder,
|
|
27
|
+
publicSurfaceCrossTester: createGitPublicSurfaceCrossTesterBuilder,
|
|
28
|
+
patchEquivalence: createGitPatchEquivalenceBuilder,
|
|
29
|
+
refReaderTools: createGitRefReaderTools,
|
|
30
|
+
candidateComparisonTools: createGitCandidateComparisonTools,
|
|
31
|
+
});
|
|
32
|
+
//# sourceMappingURL=git-namespace.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"git-namespace.js","sourceRoot":"","sources":["../../src/builders/git-namespace.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,kBAAkB,EAClB,qBAAqB,EACrB,oBAAoB,GACrB,MAAM,mCAAmC,CAAC;AAC3C,OAAO,EAAE,iCAAiC,EAAE,MAAM,4CAA4C,CAAC;AAC/F,OAAO,EAAE,6BAA6B,EAAE,MAAM,yCAAyC,CAAC;AACxF,OAAO,EAAE,2BAA2B,EAAE,MAAM,sCAAsC,CAAC;AACnF,OAAO,EAAE,6BAA6B,EAAE,MAAM,wCAAwC,CAAC;AACvF,OAAO,EAAE,4BAA4B,EAAE,MAAM,uCAAuC,CAAC;AACrF,OAAO,EAAE,0BAA0B,EAAE,MAAM,qCAAqC,CAAC;AACjF,OAAO,EAAE,gCAAgC,EAAE,MAAM,2CAA2C,CAAC;AAC7F,OAAO,EAAE,wCAAwC,EAAE,MAAM,qDAAqD,CAAC;AAC/G,OAAO,EAAE,uBAAuB,EAAE,MAAM,kCAAkC,CAAC;AAC3E,OAAO,EAAE,6BAA6B,EAAE,MAAM,wCAAwC,CAAC;AACvF,OAAO,EAAE,gCAAgC,EAAE,MAAM,4CAA4C,CAAC;AAG9F;;GAEG;AACH,MAAM,CAAC,MAAM,GAAG,GAAiB,MAAM,CAAC,MAAM,CAAe;IAC3D,kBAAkB,EAAE,qBAAqB;IACzC,iBAAiB,EAAE,oBAAoB;IACvC,eAAe,EAAE,kBAAkB;IACnC,WAAW,EAAE,2BAA2B;IACxC,aAAa,EAAE,6BAA6B;IAC5C,UAAU,EAAE,0BAA0B;IACtC,gBAAgB,EAAE,gCAAgC;IAClD,YAAY,EAAE,4BAA4B;IAC1C,aAAa,EAAE,6BAA6B;IAC5C,aAAa,EAAE,6BAA6B;IAC5C,wBAAwB,EAAE,wCAAwC;IAClE,gBAAgB,EAAE,gCAAgC;IAClD,cAAc,EAAE,uBAAuB;IACvC,wBAAwB,EAAE,iCAAiC;CAC5D,CAAC,CAAC"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import type { FsPartitionMapNode, MaybeBuilder, NodeRunnerNode } from '@paraharness/core';
|
|
2
|
+
/**
|
|
3
|
+
* Configuration options for `git.publicSurfaceCrossTester(options)` (`createGitPublicSurfaceCrossTesterBuilder`).
|
|
4
|
+
*
|
|
5
|
+
* Binds the subprocess `runner` pool and `partitionMap` whose `boundaryGlobs` identify public surface
|
|
6
|
+
* contracts for cross-candidate test transplantation.
|
|
7
|
+
*/
|
|
8
|
+
export interface GitPublicSurfaceCrossTesterOptions {
|
|
9
|
+
/** Optional unique identifier for the cross-verifier node (defaults to `'git-public-surface-cross-tester'`). */
|
|
10
|
+
readonly id?: string;
|
|
11
|
+
/** Runner pool governing subprocess slot concurrency during cross-testing. */
|
|
12
|
+
readonly runner: MaybeBuilder<NodeRunnerNode>;
|
|
13
|
+
/** Filesystem partition map defining public `boundaryGlobs` per partition. */
|
|
14
|
+
readonly partitionMap: MaybeBuilder<FsPartitionMapNode<string>>;
|
|
15
|
+
}
|
|
16
|
+
//# sourceMappingURL=git-public-surface-cross-tester-options.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"git-public-surface-cross-tester-options.d.ts","sourceRoot":"","sources":["../../src/builders/git-public-surface-cross-tester-options.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,kBAAkB,EAClB,YAAY,EACZ,cAAc,EACf,MAAM,mBAAmB,CAAC;AAE3B;;;;;GAKG;AACH,MAAM,WAAW,kCAAkC;IACjD,gHAAgH;IAChH,QAAQ,CAAC,EAAE,CAAC,EAAE,MAAM,CAAC;IACrB,8EAA8E;IAC9E,QAAQ,CAAC,MAAM,EAAE,YAAY,CAAC,cAAc,CAAC,CAAC;IAC9C,8EAA8E;IAC9E,QAAQ,CAAC,YAAY,EAAE,YAAY,CAAC,kBAAkB,CAAC,MAAM,CAAC,CAAC,CAAC;CACjE"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"git-public-surface-cross-tester-options.js","sourceRoot":"","sources":["../../src/builders/git-public-surface-cross-tester-options.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import type { BaseCheckASTNode, GitWorktreeHandle, MaybeBuilder } from '@paraharness/core';
|
|
2
|
+
/**
|
|
3
|
+
* Options for configuring branch landing reconciliation via `GitCowWorktreeBuilder.reconcileStrategy()`.
|
|
4
|
+
*
|
|
5
|
+
* Supports both `'rebase-onto-base'` (for PR-opening lanes) and `'batch-merge-train'` (for cumulative
|
|
6
|
+
* speculative merge queues), optionally binding a post-rebase verification check and maximum batch size.
|
|
7
|
+
*/
|
|
8
|
+
export interface GitReconcileStrategyOptions {
|
|
9
|
+
/** Reconciliation mode when passed via the single-object `.reconcileStrategy(options)` overload. */
|
|
10
|
+
readonly mode?: 'rebase-onto-base' | 'batch-merge-train';
|
|
11
|
+
/** Optional deterministic check executed after rebasing onto the target base branch. */
|
|
12
|
+
readonly verifyWith?: MaybeBuilder<BaseCheckASTNode<string, GitWorktreeHandle>>;
|
|
13
|
+
/** Optional maximum cumulative batch size when using `'batch-merge-train'`. */
|
|
14
|
+
readonly maxBatchSize?: number;
|
|
15
|
+
}
|
|
16
|
+
//# sourceMappingURL=git-reconcile-strategy-options.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"git-reconcile-strategy-options.d.ts","sourceRoot":"","sources":["../../src/builders/git-reconcile-strategy-options.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,gBAAgB,EAAE,iBAAiB,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAC;AAE3F;;;;;GAKG;AACH,MAAM,WAAW,2BAA2B;IAC1C,oGAAoG;IACpG,QAAQ,CAAC,IAAI,CAAC,EAAE,kBAAkB,GAAG,mBAAmB,CAAC;IACzD,wFAAwF;IACxF,QAAQ,CAAC,UAAU,CAAC,EAAE,YAAY,CAAC,gBAAgB,CAAC,MAAM,EAAE,iBAAiB,CAAC,CAAC,CAAC;IAChF,+EAA+E;IAC/E,QAAQ,CAAC,YAAY,CAAC,EAAE,MAAM,CAAC;CAChC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"git-reconcile-strategy-options.js","sourceRoot":"","sources":["../../src/builders/git-reconcile-strategy-options.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import { type GitCowWorktreeNode, type GitReconcileStrategyConfig, type GitScopeReceipt, type GitSyncReceipt, type GitWorktreeHandle } from '@paraharness/core';
|
|
2
|
+
import type { GitCowWorktreeCheckpointPolicy, GitCowWorktreeOptions } from '../git-cow-worktree-options.js';
|
|
3
|
+
import type { GitReconcileStrategyOptions } from '../git-reconcile-strategy-options.js';
|
|
4
|
+
/**
|
|
5
|
+
* Normalizes positional or object `.reconcileStrategy(...)` arguments into a frozen `GitReconcileStrategyConfig`.
|
|
6
|
+
*
|
|
7
|
+
* Extracts any `AstBuilder` passed as `verifyWith` into its passive `BaseCheckASTNode` representation.
|
|
8
|
+
*
|
|
9
|
+
* @param {'rebase-onto-base' | 'batch-merge-train' | GitReconcileStrategyOptions} modeOrOptions - Mode literal or options object.
|
|
10
|
+
* @param {GitReconcileStrategyOptions} [options] - Optional secondary options when first arg is mode.
|
|
11
|
+
*
|
|
12
|
+
* @returns {GitReconcileStrategyConfig<GitWorktreeHandle>} Frozen reconciliation strategy AST configuration.
|
|
13
|
+
*/
|
|
14
|
+
export declare function resolveReconcileStrategyConfig(modeOrOptions: 'rebase-onto-base' | 'batch-merge-train' | GitReconcileStrategyOptions, options?: GitReconcileStrategyOptions): GitReconcileStrategyConfig<GitWorktreeHandle>;
|
|
15
|
+
/**
|
|
16
|
+
* Compiles optional `GitCowWorktreeCheckpointPolicy` builder options into a frozen AST checkpoint policy object.
|
|
17
|
+
*
|
|
18
|
+
* Unwraps `partitionMap` via `extractAST` and freezes `excludeGlobs` when present.
|
|
19
|
+
*
|
|
20
|
+
* @param {GitCowWorktreeCheckpointPolicy | undefined} policy - Builder checkpoint policy configuration.
|
|
21
|
+
*
|
|
22
|
+
* @returns {GitCowWorktreeNode['checkpointPolicy']} Frozen checkpoint policy AST configuration or `undefined`.
|
|
23
|
+
*/
|
|
24
|
+
export declare function buildCheckpointPolicyConfig(policy: GitCowWorktreeCheckpointPolicy | undefined): GitCowWorktreeNode['checkpointPolicy'];
|
|
25
|
+
/**
|
|
26
|
+
* Compiles `GitCowWorktreeOptions` into an immutable, monomorphic `GitCowWorktreeNode` AST object.
|
|
27
|
+
*
|
|
28
|
+
* Populates default `conflictCleanCheck`, `receiptSchema`, and `syncSchema` fields while preserving V8 hidden classes.
|
|
29
|
+
*
|
|
30
|
+
* @param {GitCowWorktreeOptions} options - Accumulated builder configuration.
|
|
31
|
+
*
|
|
32
|
+
* @returns {GitCowWorktreeNode<GitWorktreeHandle, GitScopeReceipt, GitSyncReceipt>} Frozen `GitCowWorktreeNode` AST descriptor.
|
|
33
|
+
*/
|
|
34
|
+
export declare function buildGitCowWorktreeNode(options: GitCowWorktreeOptions): GitCowWorktreeNode<GitWorktreeHandle, GitScopeReceipt, GitSyncReceipt>;
|
|
35
|
+
//# sourceMappingURL=build-git-cow-worktree-node.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"build-git-cow-worktree-node.d.ts","sourceRoot":"","sources":["../../../src/builders/internal/build-git-cow-worktree-node.ts"],"names":[],"mappings":"AAAA,OAAO,EAGL,KAAK,kBAAkB,EACvB,KAAK,0BAA0B,EAC/B,KAAK,eAAe,EACpB,KAAK,cAAc,EACnB,KAAK,iBAAiB,EACvB,MAAM,mBAAmB,CAAC;AAE3B,OAAO,KAAK,EACV,8BAA8B,EAC9B,qBAAqB,EACtB,MAAM,gCAAgC,CAAC;AACxC,OAAO,KAAK,EAAE,2BAA2B,EAAE,MAAM,sCAAsC,CAAC;AAExF;;;;;;;;;GASG;AACH,wBAAgB,8BAA8B,CAC5C,aAAa,EAAE,kBAAkB,GAAG,mBAAmB,GAAG,2BAA2B,EACrF,OAAO,CAAC,EAAE,2BAA2B,GACpC,0BAA0B,CAAC,iBAAiB,CAAC,CAa/C;AAED;;;;;;;;GAQG;AACH,wBAAgB,2BAA2B,CACzC,MAAM,EAAE,8BAA8B,GAAG,SAAS,GACjD,kBAAkB,CAAC,kBAAkB,CAAC,CAQxC;AAED;;;;;;;;GAQG;AACH,wBAAgB,uBAAuB,CACrC,OAAO,EAAE,qBAAqB,GAC7B,kBAAkB,CAAC,iBAAiB,EAAE,eAAe,EAAE,cAAc,CAAC,CAyBxE"}
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
import { extractAST, } from '@paraharness/core';
|
|
2
|
+
import { GitScopeReceiptSchema, GitSyncReceiptSchema } from '../../schemas/git-receipts.schema.js';
|
|
3
|
+
/**
|
|
4
|
+
* Normalizes positional or object `.reconcileStrategy(...)` arguments into a frozen `GitReconcileStrategyConfig`.
|
|
5
|
+
*
|
|
6
|
+
* Extracts any `AstBuilder` passed as `verifyWith` into its passive `BaseCheckASTNode` representation.
|
|
7
|
+
*
|
|
8
|
+
* @param {'rebase-onto-base' | 'batch-merge-train' | GitReconcileStrategyOptions} modeOrOptions - Mode literal or options object.
|
|
9
|
+
* @param {GitReconcileStrategyOptions} [options] - Optional secondary options when first arg is mode.
|
|
10
|
+
*
|
|
11
|
+
* @returns {GitReconcileStrategyConfig<GitWorktreeHandle>} Frozen reconciliation strategy AST configuration.
|
|
12
|
+
*/
|
|
13
|
+
export function resolveReconcileStrategyConfig(modeOrOptions, options) {
|
|
14
|
+
const mode = typeof modeOrOptions === 'string'
|
|
15
|
+
? modeOrOptions
|
|
16
|
+
: (modeOrOptions.mode ?? 'rebase-onto-base');
|
|
17
|
+
const mergedOptions = typeof modeOrOptions === 'string' ? options : modeOrOptions;
|
|
18
|
+
const verifyWith = mergedOptions?.verifyWith !== undefined ? extractAST(mergedOptions.verifyWith) : undefined;
|
|
19
|
+
return Object.freeze({
|
|
20
|
+
mode,
|
|
21
|
+
verifyWith,
|
|
22
|
+
maxBatchSize: mergedOptions?.maxBatchSize,
|
|
23
|
+
});
|
|
24
|
+
}
|
|
25
|
+
/**
|
|
26
|
+
* Compiles optional `GitCowWorktreeCheckpointPolicy` builder options into a frozen AST checkpoint policy object.
|
|
27
|
+
*
|
|
28
|
+
* Unwraps `partitionMap` via `extractAST` and freezes `excludeGlobs` when present.
|
|
29
|
+
*
|
|
30
|
+
* @param {GitCowWorktreeCheckpointPolicy | undefined} policy - Builder checkpoint policy configuration.
|
|
31
|
+
*
|
|
32
|
+
* @returns {GitCowWorktreeNode['checkpointPolicy']} Frozen checkpoint policy AST configuration or `undefined`.
|
|
33
|
+
*/
|
|
34
|
+
export function buildCheckpointPolicyConfig(policy) {
|
|
35
|
+
if (policy === undefined)
|
|
36
|
+
return undefined;
|
|
37
|
+
return Object.freeze({
|
|
38
|
+
partitionMap: policy.partitionMap !== undefined ? extractAST(policy.partitionMap) : undefined,
|
|
39
|
+
excludeGlobs: policy.excludeGlobs !== undefined ? Object.freeze([...policy.excludeGlobs]) : undefined,
|
|
40
|
+
maxUntrackedFileSizeBytes: policy.maxUntrackedFileSizeBytes,
|
|
41
|
+
});
|
|
42
|
+
}
|
|
43
|
+
/**
|
|
44
|
+
* Compiles `GitCowWorktreeOptions` into an immutable, monomorphic `GitCowWorktreeNode` AST object.
|
|
45
|
+
*
|
|
46
|
+
* Populates default `conflictCleanCheck`, `receiptSchema`, and `syncSchema` fields while preserving V8 hidden classes.
|
|
47
|
+
*
|
|
48
|
+
* @param {GitCowWorktreeOptions} options - Accumulated builder configuration.
|
|
49
|
+
*
|
|
50
|
+
* @returns {GitCowWorktreeNode<GitWorktreeHandle, GitScopeReceipt, GitSyncReceipt>} Frozen `GitCowWorktreeNode` AST descriptor.
|
|
51
|
+
*/
|
|
52
|
+
export function buildGitCowWorktreeNode(options) {
|
|
53
|
+
const defaultCleanCheck = Object.freeze({
|
|
54
|
+
type: 'git:clean-working-tree',
|
|
55
|
+
id: 'git-clean-working-tree',
|
|
56
|
+
});
|
|
57
|
+
return Object.freeze({
|
|
58
|
+
type: 'git:cow-worktree',
|
|
59
|
+
id: options.id ?? 'git-cow-worktree',
|
|
60
|
+
capabilityTier: 'branchable',
|
|
61
|
+
supportsCheckpoints: true,
|
|
62
|
+
supportsBranching: true,
|
|
63
|
+
receiptSchema: GitScopeReceiptSchema,
|
|
64
|
+
syncSchema: GitSyncReceiptSchema,
|
|
65
|
+
repo: options.repo,
|
|
66
|
+
dir: options.dir,
|
|
67
|
+
setupCommands: Object.freeze([...(options.setupCommands ?? [])]),
|
|
68
|
+
lockfileGatePath: options.lockfileGatePath,
|
|
69
|
+
excludeFromCloneGlobs: options.excludeFromCloneGlobs !== undefined
|
|
70
|
+
? Object.freeze([...options.excludeFromCloneGlobs])
|
|
71
|
+
: undefined,
|
|
72
|
+
checkpointPolicy: buildCheckpointPolicyConfig(options.checkpointPolicy),
|
|
73
|
+
reconcileStrategy: options.reconcileStrategy,
|
|
74
|
+
conflictCleanCheck: options.conflictCleanCheck ?? defaultCleanCheck,
|
|
75
|
+
});
|
|
76
|
+
}
|
|
77
|
+
//# sourceMappingURL=build-git-cow-worktree-node.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"build-git-cow-worktree-node.js","sourceRoot":"","sources":["../../../src/builders/internal/build-git-cow-worktree-node.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,UAAU,GAOX,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EAAE,qBAAqB,EAAE,oBAAoB,EAAE,MAAM,sCAAsC,CAAC;AAOnG;;;;;;;;;GASG;AACH,MAAM,UAAU,8BAA8B,CA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MAAM,CAAC,MAAM,CAAyE;QAC3F,IAAI,EAAE,kBAAkB;QACxB,EAAE,EAAE,OAAO,CAAC,EAAE,IAAI,kBAAkB;QACpC,cAAc,EAAE,YAAY;QAC5B,mBAAmB,EAAE,IAAI;QACzB,iBAAiB,EAAE,IAAI;QACvB,aAAa,EAAE,qBAAqB;QACpC,UAAU,EAAE,oBAAoB;QAChC,IAAI,EAAE,OAAO,CAAC,IAAI;QAClB,GAAG,EAAE,OAAO,CAAC,GAAG;QAChB,aAAa,EAAE,MAAM,CAAC,MAAM,CAAC,CAAC,GAAG,CAAC,OAAO,CAAC,aAAa,IAAI,EAAE,CAAC,CAAC,CAAC;QAChE,gBAAgB,EAAE,OAAO,CAAC,gBAAgB;QAC1C,qBAAqB,EACnB,OAAO,CAAC,qBAAqB,KAAK,SAAS;YACzC,CAAC,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC,GAAG,OAAO,CAAC,qBAAqB,CAAC,CAAC;YACnD,CAAC,CAAC,SAAS;QACf,gBAAgB,EAAE,2BAA2B,CAAC,OAAO,CAAC,gBAAgB,CAAC;QACvE,iBAAiB,EAAE,OAAO,CAAC,iBAAiB;QAC5C,kBAAkB,EAAE,OAAO,CAAC,kBAAkB,IAAI,iBAAiB;KACpE,CAAC,CAAC;AACL,CAAC"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import type { RuntimeExecutorRegistrySlice } from '@paraharness/core';
|
|
2
|
+
/**
|
|
3
|
+
* Constructs a fresh `RuntimeExecutorRegistrySlice` registering all `@paraharness/git` scope, step, check, hook, cross-verifier, and tool executors.
|
|
4
|
+
*
|
|
5
|
+
* Mounts `git:cow-worktree`, `git:commit-and-push`, `git:merge-queue`, `git:clean-working-tree`,
|
|
6
|
+
* `git:snapshot-and-reset`, `git:keep-worktree`, `git:discard-branch`, `git:public-surface-cross-tester`,
|
|
7
|
+
* `git:patch-equivalence`, `git:ref-reader-tool`, and `git:candidate-comparison-tool`.
|
|
8
|
+
*
|
|
9
|
+
* @returns {RuntimeExecutorRegistrySlice} Frozen registry slice for `@paraharness/git`.
|
|
10
|
+
*/
|
|
11
|
+
export declare function createGitExecutors(): RuntimeExecutorRegistrySlice;
|
|
12
|
+
//# sourceMappingURL=create-git-executors.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"create-git-executors.d.ts","sourceRoot":"","sources":["../../src/executors/create-git-executors.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAiBV,4BAA4B,EAG7B,MAAM,mBAAmB,CAAC;AAmB3B;;;;;;;;GAQG;AACH,wBAAgB,kBAAkB,IAAI,4BAA4B,CAkFjE"}
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
import { executeGitCommitAndPushStep, executeGitMergeQueueStep, } from './git-commit-and-merge-steps.js';
|
|
2
|
+
import { GitCowWorktreeScopeDriver } from './git-cow-worktree-scope.js';
|
|
3
|
+
import { createGitCandidateComparisonToolDrivers, createGitRefReaderToolDrivers, executeGitPatchEquivalence, executeGitPublicSurfaceCrossTester, } from './git-cross-verifiers-and-tools.js';
|
|
4
|
+
import { executeGitCleanWorkingTreeCheck, executeGitDiscardBranchHook, executeGitKeepWorktreeHook, executeGitSnapshotAndResetHook, } from './git-hooks-and-checks.js';
|
|
5
|
+
/**
|
|
6
|
+
* Constructs a fresh `RuntimeExecutorRegistrySlice` registering all `@paraharness/git` scope, step, check, hook, cross-verifier, and tool executors.
|
|
7
|
+
*
|
|
8
|
+
* Mounts `git:cow-worktree`, `git:commit-and-push`, `git:merge-queue`, `git:clean-working-tree`,
|
|
9
|
+
* `git:snapshot-and-reset`, `git:keep-worktree`, `git:discard-branch`, `git:public-surface-cross-tester`,
|
|
10
|
+
* `git:patch-equivalence`, `git:ref-reader-tool`, and `git:candidate-comparison-tool`.
|
|
11
|
+
*
|
|
12
|
+
* @returns {RuntimeExecutorRegistrySlice} Frozen registry slice for `@paraharness/git`.
|
|
13
|
+
*/
|
|
14
|
+
export function createGitExecutors() {
|
|
15
|
+
return Object.freeze({
|
|
16
|
+
scopes: Object.freeze({
|
|
17
|
+
'git:cow-worktree': (node) => new GitCowWorktreeScopeDriver(node),
|
|
18
|
+
}),
|
|
19
|
+
steps: Object.freeze({
|
|
20
|
+
'git:commit-and-push': (node, input, ctx) => executeGitCommitAndPushStep(node, input, ctx),
|
|
21
|
+
'git:merge-queue': (node, input, ctx) => executeGitMergeQueueStep(node, input, ctx),
|
|
22
|
+
}),
|
|
23
|
+
checks: Object.freeze({
|
|
24
|
+
'git:clean-working-tree': (node, input, ctx) => executeGitCleanWorkingTreeCheck(node, input, ctx),
|
|
25
|
+
}),
|
|
26
|
+
abortHooks: Object.freeze({
|
|
27
|
+
'git:snapshot-and-reset': (node, input, ctx) => executeGitSnapshotAndResetHook(node, input, ctx),
|
|
28
|
+
}),
|
|
29
|
+
rewindHooks: Object.freeze({
|
|
30
|
+
'git:keep-worktree': (node, input, ctx) => executeGitKeepWorktreeHook(node, input, ctx),
|
|
31
|
+
'git:discard-branch': (node, input, ctx) => executeGitDiscardBranchHook(node, input, ctx),
|
|
32
|
+
}),
|
|
33
|
+
crossVerifiers: Object.freeze({
|
|
34
|
+
'git:public-surface-cross-tester': (node, candidates, ctx) => executeGitPublicSurfaceCrossTester(node, candidates, ctx),
|
|
35
|
+
'git:patch-equivalence': (node, candidates, ctx) => executeGitPatchEquivalence(node, candidates, ctx),
|
|
36
|
+
}),
|
|
37
|
+
tools: Object.freeze({
|
|
38
|
+
'git:ref-reader-tool': createGitRefReaderToolDrivers(),
|
|
39
|
+
'git:candidate-comparison-tool': createGitCandidateComparisonToolDrivers(),
|
|
40
|
+
}),
|
|
41
|
+
});
|
|
42
|
+
}
|
|
43
|
+
//# sourceMappingURL=create-git-executors.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"create-git-executors.js","sourceRoot":"","sources":["../../src/executors/create-git-executors.ts"],"names":[],"mappings":"AAqBA,OAAO,EACL,2BAA2B,EAC3B,w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C;YACzB,mBAAmB,EAAE,CACnB,IAAyB,EACzB,KAA+B,EAC/B,GAAkC,EAClC,EAAE,CACF,0BAA0B,CACxB,IAAI,EACJ,KAAoD,EACpD,GAA8C,CAC/C;YACH,oBAAoB,EAAE,CACpB,IAA0B,EAC1B,KAA+B,EAC/B,GAAkC,EAClC,EAAE,CACF,2BAA2B,CACzB,IAAI,EACJ,KAAoD,EACpD,GAA8C,CAC/C;SACJ,CAAC;QACF,cAAc,EAAE,MAAM,CAAC,MAAM,CAAC;YAC5B,iCAAiC,EAAE,CACjC,IAA8C,EAC9C,UAAuD,EACvD,GAAkC,EAClC,EAAE,CACF,kCAAkC,CAChC,IAAI,EACJ,UAA4E,EAC5E,GAA8C,CAC/C;YACH,uBAAuB,EAAE,CACvB,IAAsC,EACtC,UAAuD,EACvD,GAAkC,EAClC,EAAE,CACF,0BAA0B,CACxB,IAAI,EACJ,UAA4E,EAC5E,GAA8C,CAC/C;SACJ,CAAC;QACF,KAAK,EAAE,MAAM,CAAC,MAAM,CAAC;YACnB,qBAAqB,EAAE,6BAA6B,EAA+C;YACnG,+BAA+B,EAC7B,uCAAuC,EAAyD;SACnG,CAAC;KACH,CAAC,CAAC;AACL,CAAC"}
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
import type { HarnessMetaRecord } from '../schemas/git-receipts.schema.js';
|
|
2
|
+
/**
|
|
3
|
+
* Metadata descriptor for an untracked file exceeding `maxUntrackedFileSizeBytes` spilled to `<gitdir>/harness-ckpt-blobs/`.
|
|
4
|
+
*
|
|
5
|
+
* Stores the content-addressed `blobKey`, POSIX file `mode`, and byte `size` so `restoreCheckpoint`
|
|
6
|
+
* can copy the oversized file back into the working tree without bloating the temporary Git index.
|
|
7
|
+
*/
|
|
8
|
+
export interface OversizedUntrackedBlobRecord {
|
|
9
|
+
/** Content-addressed filename inside `<gitdir>/harness-ckpt-blobs/` (`${size}_${mtimeNs}_${sha256}`). */
|
|
10
|
+
readonly blobKey: string;
|
|
11
|
+
/** POSIX file permission mode bits captured via `lstat(2)`. */
|
|
12
|
+
readonly mode: number;
|
|
13
|
+
/** File size in bytes captured via `lstat(2)`. */
|
|
14
|
+
readonly size: number;
|
|
15
|
+
}
|
|
16
|
+
/**
|
|
17
|
+
* Serialized checkpoint payload produced by `GitCowWorktreeScopeDriver.serializeCheckpoint()`.
|
|
18
|
+
*
|
|
19
|
+
* Captures worktree-local `.git` metadata (`headSha`, `headRawContent`, `indexTreeSha`, `infoExcludeContent`, `meta`),
|
|
20
|
+
* the porcelain v2 `statusMap`, the temporary-index `treeSha`, and any `oversizedUntrackedBlobs`.
|
|
21
|
+
*/
|
|
22
|
+
export interface GitCheckpointPayload {
|
|
23
|
+
/** Resolved commit SHA of `HEAD` (`git rev-parse HEAD`). */
|
|
24
|
+
readonly headSha: string;
|
|
25
|
+
/** Exact raw file content of `<gitdir>/HEAD`. */
|
|
26
|
+
readonly headRawContent: string;
|
|
27
|
+
/** Tree OID of the live `<gitdir>/index` at checkpoint time. */
|
|
28
|
+
readonly indexTreeSha: string;
|
|
29
|
+
/** Raw content of `<gitdir>/info/exclude`, or `null` when absent. */
|
|
30
|
+
readonly infoExcludeContent: string | null;
|
|
31
|
+
/** Snapshot of `<gitdir>/harness-meta.json` at checkpoint time. */
|
|
32
|
+
readonly meta: HarnessMetaRecord;
|
|
33
|
+
/** Map from repository-relative file path to `${mode}:${sha256}` (or `'DELETED'`). */
|
|
34
|
+
readonly statusMap: Readonly<Record<string, string>>;
|
|
35
|
+
/** Paths ignored at checkpoint time (used when a `.gitignore` file changes mid-step). */
|
|
36
|
+
readonly ignoredPaths: readonly string[];
|
|
37
|
+
/** Digest of `node_modules` tree state at checkpoint time for tamper detection in `diffEffects`. */
|
|
38
|
+
readonly nodeModulesDigest: string;
|
|
39
|
+
/** Git tree SHA capturing `headSha` plus all dirty tracked and non-oversized untracked files. */
|
|
40
|
+
readonly treeSha: string;
|
|
41
|
+
/** Map of untracked files exceeding `maxUntrackedFileSizeBytes` stored in `<gitdir>/harness-ckpt-blobs/`. */
|
|
42
|
+
readonly oversizedUntrackedBlobs: Readonly<Record<string, OversizedUntrackedBlobRecord>>;
|
|
43
|
+
}
|
|
44
|
+
//# sourceMappingURL=git-checkpoint-payload.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"git-checkpoint-payload.d.ts","sourceRoot":"","sources":["../../src/executors/git-checkpoint-payload.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,mCAAmC,CAAC;AAE3E;;;;;GAKG;AACH,MAAM,WAAW,4BAA4B;IAC3C,yGAAyG;IACzG,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;IACzB,+DAA+D;IAC/D,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,kDAAkD;IAClD,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;CACvB;AAED;;;;;GAKG;AACH,MAAM,WAAW,oBAAoB;IACnC,4DAA4D;IAC5D,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;IACzB,iDAAiD;IACjD,QAAQ,CAAC,cAAc,EAAE,MAAM,CAAC;IAChC,gEAAgE;IAChE,QAAQ,CAAC,YAAY,EAAE,MAAM,CAAC;IAC9B,qEAAqE;IACrE,QAAQ,CAAC,kBAAkB,EAAE,MAAM,GAAG,IAAI,CAAC;IAC3C,mEAAmE;IACnE,QAAQ,CAAC,IAAI,EAAE,iBAAiB,CAAC;IACjC,sFAAsF;IACtF,QAAQ,CAAC,SAAS,EAAE,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC,CAAC;IACrD,yFAAyF;IACzF,QAAQ,CAAC,YAAY,EAAE,SAAS,MAAM,EAAE,CAAC;IACzC,oGAAoG;IACpG,QAAQ,CAAC,iBAAiB,EAAE,MAAM,CAAC;IACnC,iGAAiG;IACjG,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;IACzB,6GAA6G;IAC7G,QAAQ,CAAC,uBAAuB,EAAE,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,4BAA4B,CAAC,CAAC,CAAC;CAC1F"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"git-checkpoint-payload.js","sourceRoot":"","sources":["../../src/executors/git-checkpoint-payload.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import type { GitCommitAndPushNode, GitMergeQueueNode, GitWorktreeHandle, StepExecutionContext } from '@paraharness/core';
|
|
2
|
+
/**
|
|
3
|
+
* Executes a `GitCommitAndPushNode` (`git.commitAndPush`) step against the active `GitWorktreeHandle`.
|
|
4
|
+
*
|
|
5
|
+
* Acquires a concurrency slot from `node.runner`, flushes uncommitted edits, squashes over `baseRef`,
|
|
6
|
+
* rebases onto `origin/${resolvedBaseBranch}`, runs `verifyWith`, and pushes with `--force-with-lease`.
|
|
7
|
+
*
|
|
8
|
+
* @template TIn Step input payload type.
|
|
9
|
+
*
|
|
10
|
+
* @param {GitCommitAndPushNode<TIn>} node - Passive commit-and-push step AST node.
|
|
11
|
+
* @param {TIn} input - Step input payload.
|
|
12
|
+
* @param {StepExecutionContext<GitWorktreeHandle>} ctx - Active step execution context.
|
|
13
|
+
*
|
|
14
|
+
* @returns {Promise<void>} Resolves once the branch is pushed and `rootHandle` lineage is updated.
|
|
15
|
+
*/
|
|
16
|
+
export declare function executeGitCommitAndPushStep<TIn = unknown>(node: GitCommitAndPushNode<TIn>, input: TIn, ctx: StepExecutionContext<GitWorktreeHandle>): Promise<void>;
|
|
17
|
+
/**
|
|
18
|
+
* Executes a `GitMergeQueueNode` (`git.mergeQueue`) step using speculative cumulative rebase chains.
|
|
19
|
+
*
|
|
20
|
+
* Combines up to `node.maxBatchSize` candidate branches onto `node.targetBranch`, runs `node.verifyWith`
|
|
21
|
+
* once on the tip $R_k$, and binary-bisects on verification failure to isolate and evict offending branches.
|
|
22
|
+
*
|
|
23
|
+
* @template TIn Step input payload type.
|
|
24
|
+
* @template TOut Step output payload type.
|
|
25
|
+
*
|
|
26
|
+
* @param {GitMergeQueueNode<TIn, TOut>} node - Passive merge-queue step AST node.
|
|
27
|
+
* @param {TIn} input - Step input payload containing candidate branches or refs.
|
|
28
|
+
* @param {StepExecutionContext<GitWorktreeHandle>} ctx - Active step execution context.
|
|
29
|
+
*
|
|
30
|
+
* @returns {Promise<TOut>} Validated merge-train execution summary.
|
|
31
|
+
*/
|
|
32
|
+
export declare function executeGitMergeQueueStep<TIn = unknown, TOut = unknown>(node: GitMergeQueueNode<TIn, TOut>, input: TIn, ctx: StepExecutionContext<GitWorktreeHandle>): Promise<TOut>;
|
|
33
|
+
//# sourceMappingURL=git-commit-and-merge-steps.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"git-commit-and-merge-steps.d.ts","sourceRoot":"","sources":["../../src/executors/git-commit-and-merge-steps.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,oBAAoB,EACpB,iBAAiB,EACjB,iBAAiB,EACjB,oBAAoB,EACrB,MAAM,mBAAmB,CAAC;AAK3B;;;;;;;;;;;;;GAaG;AACH,wBAAsB,2BAA2B,CAAC,GAAG,GAAG,OAAO,EAC7D,IAAI,EAAE,oBAAoB,CAAC,GAAG,CAAC,EAC/B,KAAK,EAAE,GAAG,EACV,GAAG,EAAE,oBAAoB,CAAC,iBAAiB,CAAC,GAC3C,OAAO,CAAC,IAAI,CAAC,CAUf;AAED;;;;;;;;;;;;;;GAcG;AACH,wBAAsB,wBAAwB,CAAC,GAAG,GAAG,OAAO,EAAE,IAAI,GAAG,OAAO,EAC1E,IAAI,EAAE,iBAAiB,CAAC,GAAG,EAAE,IAAI,CAAC,EAClC,KAAK,EAAE,GAAG,EACV,GAAG,EAAE,oBAAoB,CAAC,iBAAiB,CAAC,GAC3C,OAAO,CAAC,IAAI,CAAC,CAYf"}
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
import { extractMergeTrainCandidates } from './internal/git-merge-train-bisect.js';
|
|
2
|
+
import { executeBatchMergeTrainQueue } from './internal/merge-train-runner.js';
|
|
3
|
+
import { runSquashRebaseAndPush } from './internal/squash-rebase-and-push.js';
|
|
4
|
+
/**
|
|
5
|
+
* Executes a `GitCommitAndPushNode` (`git.commitAndPush`) step against the active `GitWorktreeHandle`.
|
|
6
|
+
*
|
|
7
|
+
* Acquires a concurrency slot from `node.runner`, flushes uncommitted edits, squashes over `baseRef`,
|
|
8
|
+
* rebases onto `origin/${resolvedBaseBranch}`, runs `verifyWith`, and pushes with `--force-with-lease`.
|
|
9
|
+
*
|
|
10
|
+
* @template TIn Step input payload type.
|
|
11
|
+
*
|
|
12
|
+
* @param {GitCommitAndPushNode<TIn>} node - Passive commit-and-push step AST node.
|
|
13
|
+
* @param {TIn} input - Step input payload.
|
|
14
|
+
* @param {StepExecutionContext<GitWorktreeHandle>} ctx - Active step execution context.
|
|
15
|
+
*
|
|
16
|
+
* @returns {Promise<void>} Resolves once the branch is pushed and `rootHandle` lineage is updated.
|
|
17
|
+
*/
|
|
18
|
+
export async function executeGitCommitAndPushStep(node, input, ctx) {
|
|
19
|
+
const parsedInput = node.inputSchema !== undefined ? node.inputSchema.parse(input) : input;
|
|
20
|
+
const runStep = () => runSquashRebaseAndPush(node, parsedInput, ctx);
|
|
21
|
+
if (node.runner !== undefined && typeof ctx.getRunner === 'function') {
|
|
22
|
+
const runner = ctx.getRunner(node.runner);
|
|
23
|
+
await runner.withSlot(runStep, ctx.signal);
|
|
24
|
+
return;
|
|
25
|
+
}
|
|
26
|
+
await runStep();
|
|
27
|
+
}
|
|
28
|
+
/**
|
|
29
|
+
* Executes a `GitMergeQueueNode` (`git.mergeQueue`) step using speculative cumulative rebase chains.
|
|
30
|
+
*
|
|
31
|
+
* Combines up to `node.maxBatchSize` candidate branches onto `node.targetBranch`, runs `node.verifyWith`
|
|
32
|
+
* once on the tip $R_k$, and binary-bisects on verification failure to isolate and evict offending branches.
|
|
33
|
+
*
|
|
34
|
+
* @template TIn Step input payload type.
|
|
35
|
+
* @template TOut Step output payload type.
|
|
36
|
+
*
|
|
37
|
+
* @param {GitMergeQueueNode<TIn, TOut>} node - Passive merge-queue step AST node.
|
|
38
|
+
* @param {TIn} input - Step input payload containing candidate branches or refs.
|
|
39
|
+
* @param {StepExecutionContext<GitWorktreeHandle>} ctx - Active step execution context.
|
|
40
|
+
*
|
|
41
|
+
* @returns {Promise<TOut>} Validated merge-train execution summary.
|
|
42
|
+
*/
|
|
43
|
+
export async function executeGitMergeQueueStep(node, input, ctx) {
|
|
44
|
+
const parsedInput = node.inputSchema !== undefined ? node.inputSchema.parse(input) : input;
|
|
45
|
+
const candidates = await extractMergeTrainCandidates(parsedInput, ctx.scopeHandle, node.maxBatchSize);
|
|
46
|
+
const outcome = await executeBatchMergeTrainQueue(node, candidates, ctx);
|
|
47
|
+
if (node.outputSchema !== undefined) {
|
|
48
|
+
return node.outputSchema.parse(outcome);
|
|
49
|
+
}
|
|
50
|
+
return outcome;
|
|
51
|
+
}
|
|
52
|
+
//# sourceMappingURL=git-commit-and-merge-steps.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"git-commit-and-merge-steps.js","sourceRoot":"","sources":["../../src/executors/git-commit-and-merge-steps.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,2BAA2B,EAAE,MAAM,sCAAsC,CAAC;AACnF,OAAO,EAAE,2BAA2B,EAAE,MAAM,kCAAkC,CAAC;AAC/E,OAAO,EAAE,sBAAsB,EAAE,MAAM,sCAAsC,CAAC;AAE9E;;;;;;;;;;;;;GAaG;AACH,MAAM,CAAC,KAAK,UAAU,2BAA2B,CAC/C,IAA+B,EAC/B,KAAU,EACV,GAA4C;IAE5C,MAAM,WAAW,GAAG,IAAI,CAAC,WAAW,KAAK,SAAS,CAAC,CAAC,CAAC,IAAI,CAAC,WAAW,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC;I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