@scolladon/tsgit 2.0.1 → 3.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/README.md +14 -2
- package/dist/cjs/adapters/browser/index.cjs +1 -2
- package/dist/cjs/adapters/memory/index.cjs +1 -2
- package/dist/cjs/adapters/node/index.cjs +1 -2
- package/dist/cjs/chunks/adapter-detect-DW9fsw9d.cjs +1 -0
- package/dist/cjs/chunks/browser-http-transport-DGwW5YL7.cjs +1 -0
- package/dist/cjs/chunks/context-BcoAzPuU.cjs +0 -1
- package/dist/cjs/chunks/error-CfLWDui_.cjs +1 -0
- package/dist/cjs/chunks/index-Cy44GVR6.cjs +1 -0
- package/dist/cjs/chunks/inflate-CmCtM4-w.cjs +1 -0
- package/dist/cjs/chunks/lru-cache-1OU7JhD8.cjs +0 -1
- package/dist/cjs/chunks/memory-http-transport-CGriODcQ.cjs +1 -0
- package/dist/cjs/chunks/node-ssh-transport-PFu3ijfp.cjs +1 -0
- package/dist/cjs/chunks/{progress-CxU62NC1.cjs → progress-D8Dqbftk.cjs} +1 -2
- package/dist/cjs/chunks/readable-stream-MTA6D0Zh.cjs +0 -1
- package/dist/cjs/chunks/repository-Ci-BBxk0.cjs +1 -0
- package/dist/cjs/chunks/write-sparse-checkout-C1dsHCAD.cjs +1 -0
- package/dist/cjs/commands/index.cjs +1 -2
- package/dist/cjs/index.browser.cjs +1 -2
- package/dist/cjs/index.cjs +1 -2
- package/dist/cjs/index.default.cjs +1 -2
- package/dist/cjs/index.node.cjs +1 -2
- package/dist/cjs/operators/index.cjs +0 -1
- package/dist/cjs/primitives/index.cjs +1 -2
- package/dist/cjs/transport/index.cjs +0 -1
- package/dist/esm/adapters/browser/index.js +1 -2
- package/dist/esm/adapters/memory/index.js +1 -2
- package/dist/esm/adapters/node/index.js +1 -2
- package/dist/esm/chunks/adapter-detect-BkCMnjrI.js +1 -0
- package/dist/esm/chunks/browser-http-transport-CSxAte5h.js +1 -0
- package/dist/esm/chunks/context-CumKOV7K.js +0 -1
- package/dist/esm/chunks/error-BotOd-nD.js +1 -0
- package/dist/esm/chunks/index-DsvINN8n.js +1 -0
- package/dist/esm/chunks/inflate-BCIXqeeE.js +1 -0
- package/dist/esm/chunks/lru-cache-Cy7C7Lx2.js +0 -1
- package/dist/esm/chunks/memory-http-transport-caqmMGR1.js +1 -0
- package/dist/esm/chunks/node-ssh-transport-BgSv2IhT.js +1 -0
- package/dist/esm/chunks/{progress-BZobfl7p.js → progress-B_AJnOHx.js} +1 -2
- package/dist/esm/chunks/readable-stream-CGuf8k1J.js +0 -1
- package/dist/esm/chunks/repository-DyxknzvE.js +1 -0
- package/dist/esm/chunks/write-sparse-checkout-BwHbNKNS.js +1 -0
- package/dist/esm/commands/index.js +1 -2
- package/dist/esm/index.browser.js +1 -2
- package/dist/esm/index.default.js +1 -2
- package/dist/esm/index.js +1 -2
- package/dist/esm/index.node.js +1 -2
- package/dist/esm/operators/index.js +0 -1
- package/dist/esm/primitives/index.js +1 -2
- package/dist/esm/transport/index.js +0 -1
- package/dist/types/adapters/browser/index.d.cts +5 -3
- package/dist/types/adapters/browser/index.d.ts +5 -3
- package/dist/types/adapters/memory/index.d.cts +31 -4
- package/dist/types/adapters/memory/index.d.ts +31 -4
- package/dist/types/adapters/node/index.d.cts +146 -40
- package/dist/types/adapters/node/index.d.ts +146 -40
- package/dist/types/chunks/{context-YDw6qicq.d.cts → context-CF1YF2S8.d.cts} +165 -6
- package/dist/types/chunks/{context-CCL0_F8R.d.ts → context-sIhhtk2u.d.ts} +165 -6
- package/dist/types/chunks/{http-transport--_NdQOiw.d.cts → http-transport-DirKfK2S.d.cts} +1 -1
- package/dist/types/chunks/{http-transport--_NdQOiw.d.ts → http-transport-DirKfK2S.d.ts} +1 -1
- package/dist/types/chunks/index-B5Dps3fg.d.ts +2468 -0
- package/dist/types/chunks/index-B_A8VLaf.d.ts +1221 -0
- package/dist/types/chunks/index-Dfh8cvEs.d.cts +2468 -0
- package/dist/types/chunks/index-Dqxddhav.d.cts +1221 -0
- package/dist/types/chunks/progress-BjAKfkam.d.ts +1217 -0
- package/dist/types/chunks/progress-Ldnfb8st.d.cts +1217 -0
- package/dist/types/chunks/reflog-entry-Cqh3QrPH.d.ts +697 -0
- package/dist/types/chunks/reflog-entry-Dy-O27Dd.d.cts +697 -0
- package/dist/types/chunks/{repository-FoS_Laoy.d.ts → repository-D8QBTkEz.d.ts} +58 -20
- package/dist/types/chunks/{repository-BeifCqp0.d.cts → repository-D9YrVhcH.d.cts} +58 -20
- package/dist/types/commands/index.d.cts +4 -1259
- package/dist/types/commands/index.d.ts +4 -1259
- package/dist/types/index.browser.d.cts +7 -8
- package/dist/types/index.browser.d.ts +7 -8
- package/dist/types/index.d.cts +61 -124
- package/dist/types/index.d.ts +61 -124
- package/dist/types/index.default.d.cts +7 -8
- package/dist/types/index.default.d.ts +7 -8
- package/dist/types/index.node.d.cts +7 -8
- package/dist/types/index.node.d.ts +7 -8
- package/dist/types/primitives/index.d.cts +4 -692
- package/dist/types/primitives/index.d.ts +4 -692
- package/dist/types/transport/index.d.cts +1 -1
- package/dist/types/transport/index.d.ts +1 -1
- package/package.json +94 -28
- package/dist/cjs/adapters/browser/index.cjs.map +0 -1
- package/dist/cjs/adapters/memory/index.cjs.map +0 -1
- package/dist/cjs/adapters/node/index.cjs.map +0 -1
- package/dist/cjs/chunks/adapter-detect-CD_LcgaH.cjs +0 -2
- package/dist/cjs/chunks/adapter-detect-CD_LcgaH.cjs.map +0 -1
- package/dist/cjs/chunks/browser-http-transport-CiMRqtDS.cjs +0 -2
- package/dist/cjs/chunks/browser-http-transport-CiMRqtDS.cjs.map +0 -1
- package/dist/cjs/chunks/context-BcoAzPuU.cjs.map +0 -1
- package/dist/cjs/chunks/error-CfjFO3x_.cjs +0 -2
- package/dist/cjs/chunks/error-CfjFO3x_.cjs.map +0 -1
- package/dist/cjs/chunks/index-BWCq_5BJ.cjs +0 -2
- package/dist/cjs/chunks/index-BWCq_5BJ.cjs.map +0 -1
- package/dist/cjs/chunks/lru-cache-1OU7JhD8.cjs.map +0 -1
- package/dist/cjs/chunks/memory-http-transport-BVL6VgB-.cjs +0 -2
- package/dist/cjs/chunks/memory-http-transport-BVL6VgB-.cjs.map +0 -1
- package/dist/cjs/chunks/node-http-transport-BvfVcf02.cjs +0 -2
- package/dist/cjs/chunks/node-http-transport-BvfVcf02.cjs.map +0 -1
- package/dist/cjs/chunks/progress-CxU62NC1.cjs.map +0 -1
- package/dist/cjs/chunks/readable-stream-MTA6D0Zh.cjs.map +0 -1
- package/dist/cjs/chunks/repository-BEg2zNtx.cjs +0 -2
- package/dist/cjs/chunks/repository-BEg2zNtx.cjs.map +0 -1
- package/dist/cjs/chunks/walk-submodules-D2Sp7JEB.cjs +0 -2
- package/dist/cjs/chunks/walk-submodules-D2Sp7JEB.cjs.map +0 -1
- package/dist/cjs/commands/index.cjs.map +0 -1
- package/dist/cjs/index.browser.cjs.map +0 -1
- package/dist/cjs/index.cjs.map +0 -1
- package/dist/cjs/index.default.cjs.map +0 -1
- package/dist/cjs/index.node.cjs.map +0 -1
- package/dist/cjs/operators/index.cjs.map +0 -1
- package/dist/cjs/primitives/index.cjs.map +0 -1
- package/dist/cjs/transport/index.cjs.map +0 -1
- package/dist/esm/adapters/browser/index.js.map +0 -1
- package/dist/esm/adapters/memory/index.js.map +0 -1
- package/dist/esm/adapters/node/index.js.map +0 -1
- package/dist/esm/chunks/adapter-detect-DkZhhUhd.js +0 -2
- package/dist/esm/chunks/adapter-detect-DkZhhUhd.js.map +0 -1
- package/dist/esm/chunks/browser-http-transport-4rJkHcQu.js +0 -2
- package/dist/esm/chunks/browser-http-transport-4rJkHcQu.js.map +0 -1
- package/dist/esm/chunks/context-CumKOV7K.js.map +0 -1
- package/dist/esm/chunks/error-Dc-SRSJK.js +0 -2
- package/dist/esm/chunks/error-Dc-SRSJK.js.map +0 -1
- package/dist/esm/chunks/index-jH0UMhh-.js +0 -2
- package/dist/esm/chunks/index-jH0UMhh-.js.map +0 -1
- package/dist/esm/chunks/lru-cache-Cy7C7Lx2.js.map +0 -1
- package/dist/esm/chunks/memory-http-transport-CA1WxWBp.js +0 -2
- package/dist/esm/chunks/memory-http-transport-CA1WxWBp.js.map +0 -1
- package/dist/esm/chunks/node-http-transport-DPa2lK3T.js +0 -2
- package/dist/esm/chunks/node-http-transport-DPa2lK3T.js.map +0 -1
- package/dist/esm/chunks/progress-BZobfl7p.js.map +0 -1
- package/dist/esm/chunks/readable-stream-CGuf8k1J.js.map +0 -1
- package/dist/esm/chunks/repository-DF6ePd1x.js +0 -2
- package/dist/esm/chunks/repository-DF6ePd1x.js.map +0 -1
- package/dist/esm/chunks/walk-submodules-Dq9oGwP8.js +0 -2
- package/dist/esm/chunks/walk-submodules-Dq9oGwP8.js.map +0 -1
- package/dist/esm/commands/index.js.map +0 -1
- package/dist/esm/index.browser.js.map +0 -1
- package/dist/esm/index.default.js.map +0 -1
- package/dist/esm/index.js.map +0 -1
- package/dist/esm/index.node.js.map +0 -1
- package/dist/esm/operators/index.js.map +0 -1
- package/dist/esm/primitives/index.js.map +0 -1
- package/dist/esm/transport/index.js.map +0 -1
- package/dist/types/chunks/index-entry-DtEbVpOG.d.cts +0 -47
- package/dist/types/chunks/index-entry-UD4dvtKh.d.ts +0 -47
- package/dist/types/chunks/progress-7KKiXXfX.d.ts +0 -405
- package/dist/types/chunks/progress-By8yFaUE.d.cts +0 -405
- package/dist/types/chunks/reflog-entry-BbNnXCTC.d.cts +0 -368
- package/dist/types/chunks/reflog-entry-CSzjnZd4.d.ts +0 -368
- package/dist/types/chunks/write-tree-C3oNxOlX.d.cts +0 -196
- package/dist/types/chunks/write-tree-DRI-LzSr.d.ts +0 -196
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
1
|
+
import { a3 as StatTreeDiff, a8 as TreeDiff } from './reflog-entry-Cqh3QrPH.js';
|
|
2
|
+
import { g as FileSystem, h as HashService, a as Compressor, p as RepositoryConfig, L as Logger, P as ProgressReporter, m as HookRunner, C as CommandRunner, c as Context } from './context-sIhhtk2u.js';
|
|
3
|
+
import { d1 as add, d2 as archive, dh as blame, p as BranchNamespace, x as BundleNamespace, dr as catFile, ds as checkout, P as CherryPickNamespace, dy as clone, dz as commit, a5 as ConfigNamespace, ah as DescribeOptions, b1 as NameRevResult, ai as DescribeResult, aj as DiffOptions, dP as fetch, dQ as fetchMissing, dR as fsck, dS as grep, dU as init, dW as log, aU as MergeNamespace, d_ as mv, d$ as nameRev, b7 as NotesNamespace, e4 as pull, e5 as push, e7 as readFileAt, e6 as rangeDiff, bq as RebaseNamespace, ed as reflog, bB as RemoteNamespace, ek as reset, bQ as RevertNamespace, el as revParse, eq as rm, er as shortlog, c1 as ShowOptions, c2 as ShowResult, ca as SparseCheckoutNamespace, ck as StashNamespace, eF as status, cA as SubmoduleNamespace, cN as TagNamespace, eP as whatchanged, cZ as WorktreeNamespace } from './index-B5Dps3fg.js';
|
|
4
|
+
import { y as bisectMidpoint, J as catFileBatch, Q as createCommit, U as diffTrees, a3 as getRepoRoot, a5 as hashBlob, a8 as isIgnored, af as mergeBase, ah as readBlob, al as readIndex, am as readObject, aq as readTree, av as resolveRef, ay as runHook, aF as streamBlob, aL as updateRef, aN as walkCommits, aO as walkCommitsByDate, aP as walkSubmodules, aQ as walkTree, aR as walkWorkingTree, aT as writeObject, aW as writeTree } from './index-B_A8VLaf.js';
|
|
5
|
+
import { o as SnapshotFactory } from './progress-BjAKfkam.js';
|
|
6
|
+
import { b as HttpTransport } from './http-transport-DirKfK2S.js';
|
|
7
7
|
|
|
8
8
|
/**
|
|
9
9
|
* Helper that strips the leading `Context` parameter from a function type so
|
|
@@ -41,6 +41,17 @@ interface OpenRepositoryOptions {
|
|
|
41
41
|
* holds. Pass `false` when operating on a repository you do not trust.
|
|
42
42
|
*/
|
|
43
43
|
readonly hooks?: HookRunner | false;
|
|
44
|
+
/**
|
|
45
|
+
* Custom merge-driver command runner. Omit to inherit the runtime default
|
|
46
|
+
* (Node wires one; the browser does not). Pass `false` to disable external
|
|
47
|
+
* merge drivers — a configured `[merge "<driver>"].driver` then falls back to
|
|
48
|
+
* the built-in merge.
|
|
49
|
+
*
|
|
50
|
+
* WARNING: a wired runner executes the `driver` shell command from
|
|
51
|
+
* `.git/config`, inheriting the calling process's environment. Pass `false`
|
|
52
|
+
* when operating on a repository whose config you do not trust.
|
|
53
|
+
*/
|
|
54
|
+
readonly command?: CommandRunner | false;
|
|
44
55
|
/**
|
|
45
56
|
* Opt OUT of adapter validator wrapping for `fs` and `transport`. NEVER set
|
|
46
57
|
* with adapters whose code you do not control; a raw transport receives
|
|
@@ -54,10 +65,13 @@ interface OpenRepositoryOptions {
|
|
|
54
65
|
* users never see Context except through `repo.ctx`.
|
|
55
66
|
*/
|
|
56
67
|
interface Repository {
|
|
57
|
-
readonly abortMerge: BindCtx<typeof abortMerge>;
|
|
58
68
|
readonly add: BindCtx<typeof add>;
|
|
69
|
+
readonly archive: BindCtx<typeof archive>;
|
|
70
|
+
readonly blame: BindCtx<typeof blame>;
|
|
59
71
|
/** Nested `repo.branch.{list,create,delete,rename}` namespace. */
|
|
60
72
|
readonly branch: BranchNamespace;
|
|
73
|
+
/** Nested `repo.bundle.{create,verify,listHeads}` namespace. */
|
|
74
|
+
readonly bundle: BundleNamespace;
|
|
61
75
|
readonly catFile: BindCtx<typeof catFile>;
|
|
62
76
|
readonly checkout: BindCtx<typeof checkout>;
|
|
63
77
|
/** Nested `repo.cherryPick.{run,continue,skip,abort}` namespace. */
|
|
@@ -66,23 +80,34 @@ interface Repository {
|
|
|
66
80
|
readonly commit: BindCtx<typeof commit>;
|
|
67
81
|
/** Nested `repo.config.{get,set,unset,unsetAll,getAll,getRegexp,list,renameSection,removeSection}` (ADR-181). */
|
|
68
82
|
readonly config: ConfigNamespace;
|
|
69
|
-
readonly
|
|
83
|
+
readonly describe: {
|
|
84
|
+
(rev: string | undefined, opts: DescribeOptions & {
|
|
85
|
+
contains: true;
|
|
86
|
+
}): Promise<NameRevResult>;
|
|
87
|
+
(rev?: string, opts?: DescribeOptions): Promise<DescribeResult>;
|
|
88
|
+
};
|
|
70
89
|
readonly diff: {
|
|
71
|
-
(opts?: DiffOptions & {
|
|
72
|
-
format?: 'tree';
|
|
73
|
-
}): Promise<TreeDiff>;
|
|
74
90
|
(opts: DiffOptions & {
|
|
75
|
-
|
|
76
|
-
}): Promise<
|
|
91
|
+
withStat: true;
|
|
92
|
+
}): Promise<StatTreeDiff>;
|
|
93
|
+
(opts?: DiffOptions): Promise<TreeDiff>;
|
|
77
94
|
};
|
|
78
95
|
readonly fetch: BindCtx<typeof fetch>;
|
|
79
96
|
readonly fetchMissing: BindCtx<typeof fetchMissing>;
|
|
97
|
+
readonly fsck: BindCtx<typeof fsck>;
|
|
98
|
+
readonly grep: BindCtx<typeof grep>;
|
|
80
99
|
readonly init: BindCtx<typeof init>;
|
|
81
100
|
readonly log: BindCtx<typeof log>;
|
|
82
|
-
|
|
101
|
+
/** Nested `repo.merge.{run,continue,abort}` namespace. */
|
|
102
|
+
readonly merge: MergeNamespace;
|
|
83
103
|
readonly mv: BindCtx<typeof mv>;
|
|
104
|
+
readonly nameRev: BindCtx<typeof nameRev>;
|
|
105
|
+
/** Nested `repo.notes.{add,read,list,remove}` namespace. */
|
|
106
|
+
readonly notes: NotesNamespace;
|
|
84
107
|
readonly pull: BindCtx<typeof pull>;
|
|
85
108
|
readonly push: BindCtx<typeof push>;
|
|
109
|
+
readonly readFileAt: BindCtx<typeof readFileAt>;
|
|
110
|
+
readonly rangeDiff: BindCtx<typeof rangeDiff>;
|
|
86
111
|
/** Nested `repo.rebase.{run,continue,skip,abort}` namespace. */
|
|
87
112
|
readonly rebase: RebaseNamespace;
|
|
88
113
|
readonly reflog: BindCtx<typeof reflog>;
|
|
@@ -93,15 +118,31 @@ interface Repository {
|
|
|
93
118
|
readonly revert: RevertNamespace;
|
|
94
119
|
readonly revParse: BindCtx<typeof revParse>;
|
|
95
120
|
readonly rm: BindCtx<typeof rm>;
|
|
121
|
+
readonly shortlog: BindCtx<typeof shortlog>;
|
|
122
|
+
readonly show: {
|
|
123
|
+
(rev: ReadonlyArray<string>, opts: ShowOptions & {
|
|
124
|
+
withStat: true;
|
|
125
|
+
}): Promise<ReadonlyArray<ShowResult<StatTreeDiff>>>;
|
|
126
|
+
(rev: string | undefined, opts: ShowOptions & {
|
|
127
|
+
withStat: true;
|
|
128
|
+
}): Promise<ShowResult<StatTreeDiff>>;
|
|
129
|
+
(rev: ReadonlyArray<string>, opts?: ShowOptions): Promise<ReadonlyArray<ShowResult>>;
|
|
130
|
+
(rev?: string, opts?: ShowOptions): Promise<ShowResult>;
|
|
131
|
+
};
|
|
96
132
|
/** Nested `repo.sparseCheckout.{list,set,add,reapply,disable}` namespace. */
|
|
97
133
|
readonly sparseCheckout: SparseCheckoutNamespace;
|
|
98
134
|
/** Nested `repo.stash.{push,list,apply,pop,drop}` namespace. */
|
|
99
135
|
readonly stash: StashNamespace;
|
|
100
136
|
readonly status: BindCtx<typeof status>;
|
|
101
|
-
|
|
137
|
+
/** Nested `repo.submodule.{list,add,init,update,sync,deinit}` namespace. */
|
|
138
|
+
readonly submodule: SubmoduleNamespace;
|
|
102
139
|
/** Nested `repo.tag.{list,create,delete}` namespace. */
|
|
103
140
|
readonly tag: TagNamespace;
|
|
141
|
+
readonly whatchanged: BindCtx<typeof whatchanged>;
|
|
142
|
+
/** Nested `repo.worktree.{list,add,move,remove}` namespace. */
|
|
143
|
+
readonly worktree: WorktreeNamespace;
|
|
104
144
|
readonly primitives: {
|
|
145
|
+
readonly bisectMidpoint: BindCtx<typeof bisectMidpoint>;
|
|
105
146
|
readonly catFileBatch: BindCtx<typeof catFileBatch>;
|
|
106
147
|
readonly createCommit: BindCtx<typeof createCommit>;
|
|
107
148
|
readonly diffTrees: BindCtx<typeof diffTrees>;
|
|
@@ -113,19 +154,16 @@ interface Repository {
|
|
|
113
154
|
readonly readIndex: BindCtx<typeof readIndex>;
|
|
114
155
|
readonly readObject: BindCtx<typeof readObject>;
|
|
115
156
|
readonly readTree: BindCtx<typeof readTree>;
|
|
116
|
-
readonly recordRefUpdate: BindCtx<typeof recordRefUpdate>;
|
|
117
157
|
readonly resolveRef: BindCtx<typeof resolveRef>;
|
|
118
158
|
readonly runHook: BindCtx<typeof runHook>;
|
|
119
|
-
readonly
|
|
120
|
-
readonly stageEntry: BindCtx<typeof stageEntry>;
|
|
121
|
-
readonly unstageEntry: BindCtx<typeof unstageEntry>;
|
|
159
|
+
readonly streamBlob: BindCtx<typeof streamBlob>;
|
|
122
160
|
readonly updateRef: BindCtx<typeof updateRef>;
|
|
123
161
|
readonly walkCommits: BindCtx<typeof walkCommits>;
|
|
162
|
+
readonly walkCommitsByDate: BindCtx<typeof walkCommitsByDate>;
|
|
124
163
|
readonly walkSubmodules: BindCtx<typeof walkSubmodules>;
|
|
125
164
|
readonly walkTree: BindCtx<typeof walkTree>;
|
|
126
165
|
readonly walkWorkingTree: BindCtx<typeof walkWorkingTree>;
|
|
127
166
|
readonly writeObject: BindCtx<typeof writeObject>;
|
|
128
|
-
readonly writeSymbolicRef: BindCtx<typeof writeSymbolicRef>;
|
|
129
167
|
readonly writeTree: BindCtx<typeof writeTree>;
|
|
130
168
|
};
|
|
131
169
|
/**
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
1
|
+
import { a3 as StatTreeDiff, a8 as TreeDiff } from './reflog-entry-Dy-O27Dd.cjs';
|
|
2
|
+
import { g as FileSystem, h as HashService, a as Compressor, p as RepositoryConfig, L as Logger, P as ProgressReporter, m as HookRunner, C as CommandRunner, c as Context } from './context-CF1YF2S8.cjs';
|
|
3
|
+
import { d1 as add, d2 as archive, dh as blame, p as BranchNamespace, x as BundleNamespace, dr as catFile, ds as checkout, P as CherryPickNamespace, dy as clone, dz as commit, a5 as ConfigNamespace, ah as DescribeOptions, b1 as NameRevResult, ai as DescribeResult, aj as DiffOptions, dP as fetch, dQ as fetchMissing, dR as fsck, dS as grep, dU as init, dW as log, aU as MergeNamespace, d_ as mv, d$ as nameRev, b7 as NotesNamespace, e4 as pull, e5 as push, e7 as readFileAt, e6 as rangeDiff, bq as RebaseNamespace, ed as reflog, bB as RemoteNamespace, ek as reset, bQ as RevertNamespace, el as revParse, eq as rm, er as shortlog, c1 as ShowOptions, c2 as ShowResult, ca as SparseCheckoutNamespace, ck as StashNamespace, eF as status, cA as SubmoduleNamespace, cN as TagNamespace, eP as whatchanged, cZ as WorktreeNamespace } from './index-Dfh8cvEs.cjs';
|
|
4
|
+
import { y as bisectMidpoint, J as catFileBatch, Q as createCommit, U as diffTrees, a3 as getRepoRoot, a5 as hashBlob, a8 as isIgnored, af as mergeBase, ah as readBlob, al as readIndex, am as readObject, aq as readTree, av as resolveRef, ay as runHook, aF as streamBlob, aL as updateRef, aN as walkCommits, aO as walkCommitsByDate, aP as walkSubmodules, aQ as walkTree, aR as walkWorkingTree, aT as writeObject, aW as writeTree } from './index-Dqxddhav.cjs';
|
|
5
|
+
import { o as SnapshotFactory } from './progress-Ldnfb8st.cjs';
|
|
6
|
+
import { b as HttpTransport } from './http-transport-DirKfK2S.cjs';
|
|
7
7
|
|
|
8
8
|
/**
|
|
9
9
|
* Helper that strips the leading `Context` parameter from a function type so
|
|
@@ -41,6 +41,17 @@ interface OpenRepositoryOptions {
|
|
|
41
41
|
* holds. Pass `false` when operating on a repository you do not trust.
|
|
42
42
|
*/
|
|
43
43
|
readonly hooks?: HookRunner | false;
|
|
44
|
+
/**
|
|
45
|
+
* Custom merge-driver command runner. Omit to inherit the runtime default
|
|
46
|
+
* (Node wires one; the browser does not). Pass `false` to disable external
|
|
47
|
+
* merge drivers — a configured `[merge "<driver>"].driver` then falls back to
|
|
48
|
+
* the built-in merge.
|
|
49
|
+
*
|
|
50
|
+
* WARNING: a wired runner executes the `driver` shell command from
|
|
51
|
+
* `.git/config`, inheriting the calling process's environment. Pass `false`
|
|
52
|
+
* when operating on a repository whose config you do not trust.
|
|
53
|
+
*/
|
|
54
|
+
readonly command?: CommandRunner | false;
|
|
44
55
|
/**
|
|
45
56
|
* Opt OUT of adapter validator wrapping for `fs` and `transport`. NEVER set
|
|
46
57
|
* with adapters whose code you do not control; a raw transport receives
|
|
@@ -54,10 +65,13 @@ interface OpenRepositoryOptions {
|
|
|
54
65
|
* users never see Context except through `repo.ctx`.
|
|
55
66
|
*/
|
|
56
67
|
interface Repository {
|
|
57
|
-
readonly abortMerge: BindCtx<typeof abortMerge>;
|
|
58
68
|
readonly add: BindCtx<typeof add>;
|
|
69
|
+
readonly archive: BindCtx<typeof archive>;
|
|
70
|
+
readonly blame: BindCtx<typeof blame>;
|
|
59
71
|
/** Nested `repo.branch.{list,create,delete,rename}` namespace. */
|
|
60
72
|
readonly branch: BranchNamespace;
|
|
73
|
+
/** Nested `repo.bundle.{create,verify,listHeads}` namespace. */
|
|
74
|
+
readonly bundle: BundleNamespace;
|
|
61
75
|
readonly catFile: BindCtx<typeof catFile>;
|
|
62
76
|
readonly checkout: BindCtx<typeof checkout>;
|
|
63
77
|
/** Nested `repo.cherryPick.{run,continue,skip,abort}` namespace. */
|
|
@@ -66,23 +80,34 @@ interface Repository {
|
|
|
66
80
|
readonly commit: BindCtx<typeof commit>;
|
|
67
81
|
/** Nested `repo.config.{get,set,unset,unsetAll,getAll,getRegexp,list,renameSection,removeSection}` (ADR-181). */
|
|
68
82
|
readonly config: ConfigNamespace;
|
|
69
|
-
readonly
|
|
83
|
+
readonly describe: {
|
|
84
|
+
(rev: string | undefined, opts: DescribeOptions & {
|
|
85
|
+
contains: true;
|
|
86
|
+
}): Promise<NameRevResult>;
|
|
87
|
+
(rev?: string, opts?: DescribeOptions): Promise<DescribeResult>;
|
|
88
|
+
};
|
|
70
89
|
readonly diff: {
|
|
71
|
-
(opts?: DiffOptions & {
|
|
72
|
-
format?: 'tree';
|
|
73
|
-
}): Promise<TreeDiff>;
|
|
74
90
|
(opts: DiffOptions & {
|
|
75
|
-
|
|
76
|
-
}): Promise<
|
|
91
|
+
withStat: true;
|
|
92
|
+
}): Promise<StatTreeDiff>;
|
|
93
|
+
(opts?: DiffOptions): Promise<TreeDiff>;
|
|
77
94
|
};
|
|
78
95
|
readonly fetch: BindCtx<typeof fetch>;
|
|
79
96
|
readonly fetchMissing: BindCtx<typeof fetchMissing>;
|
|
97
|
+
readonly fsck: BindCtx<typeof fsck>;
|
|
98
|
+
readonly grep: BindCtx<typeof grep>;
|
|
80
99
|
readonly init: BindCtx<typeof init>;
|
|
81
100
|
readonly log: BindCtx<typeof log>;
|
|
82
|
-
|
|
101
|
+
/** Nested `repo.merge.{run,continue,abort}` namespace. */
|
|
102
|
+
readonly merge: MergeNamespace;
|
|
83
103
|
readonly mv: BindCtx<typeof mv>;
|
|
104
|
+
readonly nameRev: BindCtx<typeof nameRev>;
|
|
105
|
+
/** Nested `repo.notes.{add,read,list,remove}` namespace. */
|
|
106
|
+
readonly notes: NotesNamespace;
|
|
84
107
|
readonly pull: BindCtx<typeof pull>;
|
|
85
108
|
readonly push: BindCtx<typeof push>;
|
|
109
|
+
readonly readFileAt: BindCtx<typeof readFileAt>;
|
|
110
|
+
readonly rangeDiff: BindCtx<typeof rangeDiff>;
|
|
86
111
|
/** Nested `repo.rebase.{run,continue,skip,abort}` namespace. */
|
|
87
112
|
readonly rebase: RebaseNamespace;
|
|
88
113
|
readonly reflog: BindCtx<typeof reflog>;
|
|
@@ -93,15 +118,31 @@ interface Repository {
|
|
|
93
118
|
readonly revert: RevertNamespace;
|
|
94
119
|
readonly revParse: BindCtx<typeof revParse>;
|
|
95
120
|
readonly rm: BindCtx<typeof rm>;
|
|
121
|
+
readonly shortlog: BindCtx<typeof shortlog>;
|
|
122
|
+
readonly show: {
|
|
123
|
+
(rev: ReadonlyArray<string>, opts: ShowOptions & {
|
|
124
|
+
withStat: true;
|
|
125
|
+
}): Promise<ReadonlyArray<ShowResult<StatTreeDiff>>>;
|
|
126
|
+
(rev: string | undefined, opts: ShowOptions & {
|
|
127
|
+
withStat: true;
|
|
128
|
+
}): Promise<ShowResult<StatTreeDiff>>;
|
|
129
|
+
(rev: ReadonlyArray<string>, opts?: ShowOptions): Promise<ReadonlyArray<ShowResult>>;
|
|
130
|
+
(rev?: string, opts?: ShowOptions): Promise<ShowResult>;
|
|
131
|
+
};
|
|
96
132
|
/** Nested `repo.sparseCheckout.{list,set,add,reapply,disable}` namespace. */
|
|
97
133
|
readonly sparseCheckout: SparseCheckoutNamespace;
|
|
98
134
|
/** Nested `repo.stash.{push,list,apply,pop,drop}` namespace. */
|
|
99
135
|
readonly stash: StashNamespace;
|
|
100
136
|
readonly status: BindCtx<typeof status>;
|
|
101
|
-
|
|
137
|
+
/** Nested `repo.submodule.{list,add,init,update,sync,deinit}` namespace. */
|
|
138
|
+
readonly submodule: SubmoduleNamespace;
|
|
102
139
|
/** Nested `repo.tag.{list,create,delete}` namespace. */
|
|
103
140
|
readonly tag: TagNamespace;
|
|
141
|
+
readonly whatchanged: BindCtx<typeof whatchanged>;
|
|
142
|
+
/** Nested `repo.worktree.{list,add,move,remove}` namespace. */
|
|
143
|
+
readonly worktree: WorktreeNamespace;
|
|
104
144
|
readonly primitives: {
|
|
145
|
+
readonly bisectMidpoint: BindCtx<typeof bisectMidpoint>;
|
|
105
146
|
readonly catFileBatch: BindCtx<typeof catFileBatch>;
|
|
106
147
|
readonly createCommit: BindCtx<typeof createCommit>;
|
|
107
148
|
readonly diffTrees: BindCtx<typeof diffTrees>;
|
|
@@ -113,19 +154,16 @@ interface Repository {
|
|
|
113
154
|
readonly readIndex: BindCtx<typeof readIndex>;
|
|
114
155
|
readonly readObject: BindCtx<typeof readObject>;
|
|
115
156
|
readonly readTree: BindCtx<typeof readTree>;
|
|
116
|
-
readonly recordRefUpdate: BindCtx<typeof recordRefUpdate>;
|
|
117
157
|
readonly resolveRef: BindCtx<typeof resolveRef>;
|
|
118
158
|
readonly runHook: BindCtx<typeof runHook>;
|
|
119
|
-
readonly
|
|
120
|
-
readonly stageEntry: BindCtx<typeof stageEntry>;
|
|
121
|
-
readonly unstageEntry: BindCtx<typeof unstageEntry>;
|
|
159
|
+
readonly streamBlob: BindCtx<typeof streamBlob>;
|
|
122
160
|
readonly updateRef: BindCtx<typeof updateRef>;
|
|
123
161
|
readonly walkCommits: BindCtx<typeof walkCommits>;
|
|
162
|
+
readonly walkCommitsByDate: BindCtx<typeof walkCommitsByDate>;
|
|
124
163
|
readonly walkSubmodules: BindCtx<typeof walkSubmodules>;
|
|
125
164
|
readonly walkTree: BindCtx<typeof walkTree>;
|
|
126
165
|
readonly walkWorkingTree: BindCtx<typeof walkWorkingTree>;
|
|
127
166
|
readonly writeObject: BindCtx<typeof writeObject>;
|
|
128
|
-
readonly writeSymbolicRef: BindCtx<typeof writeSymbolicRef>;
|
|
129
167
|
readonly writeTree: BindCtx<typeof writeTree>;
|
|
130
168
|
};
|
|
131
169
|
/**
|