@microwiseai/snapshot 0.5.0 → 0.5.1
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/node_modules/@gitdot/clone-lib/README.md +117 -0
- package/node_modules/@gitdot/clone-lib/dist/bin/gitdot-resolve.d.ts +9 -0
- package/node_modules/@gitdot/clone-lib/dist/bin/gitdot-resolve.d.ts.map +1 -0
- package/node_modules/@gitdot/clone-lib/dist/bin/gitdot-resolve.js +154 -0
- package/node_modules/@gitdot/clone-lib/dist/bin/gitdot-resolve.js.map +1 -0
- package/node_modules/@gitdot/clone-lib/dist/clone.d.ts +21 -0
- package/node_modules/@gitdot/clone-lib/dist/clone.d.ts.map +1 -0
- package/node_modules/@gitdot/clone-lib/dist/clone.js +228 -0
- package/node_modules/@gitdot/clone-lib/dist/clone.js.map +1 -0
- package/node_modules/@gitdot/clone-lib/dist/dotpath.d.ts +10 -0
- package/node_modules/@gitdot/clone-lib/dist/dotpath.d.ts.map +1 -0
- package/node_modules/@gitdot/clone-lib/dist/dotpath.js +27 -0
- package/node_modules/@gitdot/clone-lib/dist/dotpath.js.map +1 -0
- package/node_modules/@gitdot/clone-lib/dist/git.d.ts +23 -0
- package/node_modules/@gitdot/clone-lib/dist/git.d.ts.map +1 -0
- package/node_modules/@gitdot/clone-lib/dist/git.js +134 -0
- package/node_modules/@gitdot/clone-lib/dist/git.js.map +1 -0
- package/node_modules/@gitdot/clone-lib/dist/index.d.ts +17 -0
- package/node_modules/@gitdot/clone-lib/dist/index.d.ts.map +1 -0
- package/node_modules/@gitdot/clone-lib/dist/index.js +35 -0
- package/node_modules/@gitdot/clone-lib/dist/index.js.map +1 -0
- package/node_modules/@gitdot/clone-lib/dist/lock.d.ts +24 -0
- package/node_modules/@gitdot/clone-lib/dist/lock.d.ts.map +1 -0
- package/node_modules/@gitdot/clone-lib/dist/lock.js +97 -0
- package/node_modules/@gitdot/clone-lib/dist/lock.js.map +1 -0
- package/node_modules/@gitdot/clone-lib/dist/resolve/gitlab.d.ts +15 -0
- package/node_modules/@gitdot/clone-lib/dist/resolve/gitlab.d.ts.map +1 -0
- package/node_modules/@gitdot/clone-lib/dist/resolve/gitlab.js +124 -0
- package/node_modules/@gitdot/clone-lib/dist/resolve/gitlab.js.map +1 -0
- package/node_modules/@gitdot/clone-lib/dist/resolve/index.d.ts +12 -0
- package/node_modules/@gitdot/clone-lib/dist/resolve/index.d.ts.map +1 -0
- package/node_modules/@gitdot/clone-lib/dist/resolve/index.js +31 -0
- package/node_modules/@gitdot/clone-lib/dist/resolve/index.js.map +1 -0
- package/node_modules/@gitdot/clone-lib/dist/resolve/manifest.d.ts +32 -0
- package/node_modules/@gitdot/clone-lib/dist/resolve/manifest.d.ts.map +1 -0
- package/node_modules/@gitdot/clone-lib/dist/resolve/manifest.js +159 -0
- package/node_modules/@gitdot/clone-lib/dist/resolve/manifest.js.map +1 -0
- package/node_modules/@gitdot/clone-lib/dist/resolve/member.d.ts +44 -0
- package/node_modules/@gitdot/clone-lib/dist/resolve/member.d.ts.map +1 -0
- package/node_modules/@gitdot/clone-lib/dist/resolve/member.js +163 -0
- package/node_modules/@gitdot/clone-lib/dist/resolve/member.js.map +1 -0
- package/node_modules/@gitdot/clone-lib/dist/resolve/resolve.d.ts +18 -0
- package/node_modules/@gitdot/clone-lib/dist/resolve/resolve.d.ts.map +1 -0
- package/node_modules/@gitdot/clone-lib/dist/resolve/resolve.js +155 -0
- package/node_modules/@gitdot/clone-lib/dist/resolve/resolve.js.map +1 -0
- package/node_modules/@gitdot/clone-lib/dist/types.d.ts +225 -0
- package/node_modules/@gitdot/clone-lib/dist/types.d.ts.map +1 -0
- package/node_modules/@gitdot/clone-lib/dist/types.js +9 -0
- package/node_modules/@gitdot/clone-lib/dist/types.js.map +1 -0
- package/node_modules/@gitdot/clone-lib/package.json +53 -0
- package/package.json +4 -2
|
@@ -0,0 +1,225 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Public type surface for @gitdot/clone-lib (RESOLVED-LOCK-SPEC S2/S3/S4).
|
|
3
|
+
*
|
|
4
|
+
* Consumers (snapshot / skit / glpkg) import these to type their adapters:
|
|
5
|
+
* import type { ResolvedLock, Member, CloneReport, Manifest } from '@gitdot/clone-lib';
|
|
6
|
+
*/
|
|
7
|
+
/** Clone strategy: pin an exact commit, or track the default-branch HEAD. */
|
|
8
|
+
export type CloneMode = 'pinned' | 'head';
|
|
9
|
+
/** Resolved repo visibility (drives the S3 credential pre-flight). */
|
|
10
|
+
export type Visibility = 'public' | 'private' | 'unknown';
|
|
11
|
+
/** How a coordinate was resolved (makes GAP-1 guesswork explicit + checkable). */
|
|
12
|
+
export type Provenance = 'manifest-repository' | 'gitlab-api' | 'package-lock-projectid' | 'convention-guess' | null;
|
|
13
|
+
/** Member kind (reused enum from SUBSET-MANIFEST). */
|
|
14
|
+
export type MemberType = 'npm-lib' | 'app/worker' | 'static-asset' | 'meta';
|
|
15
|
+
/** Structured git failure kind emitted by the GitRunner. */
|
|
16
|
+
export type GitErrorKind = 'not-found' | 'no-access' | 'failed';
|
|
17
|
+
/** A real, git-clonable coordinate. `cloneUrl` is REQUIRED for a finished lock. */
|
|
18
|
+
export interface RepoCoordinate {
|
|
19
|
+
cloneUrl?: string;
|
|
20
|
+
projectPath?: string;
|
|
21
|
+
projectId?: number;
|
|
22
|
+
}
|
|
23
|
+
/** Full resolved ref; `sha` === Member.commitSha. */
|
|
24
|
+
export interface Ref {
|
|
25
|
+
branch: string | null;
|
|
26
|
+
tag: string | null;
|
|
27
|
+
sha: string | null;
|
|
28
|
+
dirty: boolean;
|
|
29
|
+
}
|
|
30
|
+
/** One fully-resolved node of the install closure. */
|
|
31
|
+
export interface Member {
|
|
32
|
+
/** declared gitdot dot-identity, separate from npmName (F2). */
|
|
33
|
+
id: string;
|
|
34
|
+
npmName: string;
|
|
35
|
+
/** resolved GitLab group — pinned PER MEMBER (multi-tenant rule S2). */
|
|
36
|
+
gitlabGroup: string | null;
|
|
37
|
+
repoCoordinate: RepoCoordinate;
|
|
38
|
+
visibility: Visibility;
|
|
39
|
+
version: string | null;
|
|
40
|
+
/** exact commit the version was published from (tag → sha pin). */
|
|
41
|
+
commitSha: string | null;
|
|
42
|
+
ref: Ref;
|
|
43
|
+
memberType: MemberType;
|
|
44
|
+
/** install channel that declared it (glpkg | npm-proxy | skit | …). */
|
|
45
|
+
installer: string;
|
|
46
|
+
provenance: Provenance;
|
|
47
|
+
}
|
|
48
|
+
/** `source` block — the only part that differs between skit/snapshot/glpkg locks. */
|
|
49
|
+
export interface LockSource {
|
|
50
|
+
manifest: string | null;
|
|
51
|
+
manifestVersion: string | null;
|
|
52
|
+
registry: Record<string, unknown>;
|
|
53
|
+
derivedFrom: 'package-lock.json' | 'manifest' | string;
|
|
54
|
+
}
|
|
55
|
+
/** The one resolved-lock schema; skit/snapshot/glpkg.lock.json are instances of it. */
|
|
56
|
+
export interface ResolvedLock {
|
|
57
|
+
lockVersion: 1;
|
|
58
|
+
kind: 'resolved-lock';
|
|
59
|
+
subset?: string;
|
|
60
|
+
source: LockSource;
|
|
61
|
+
resolvedAt: string;
|
|
62
|
+
members: Member[];
|
|
63
|
+
edges: Array<[string, string]>;
|
|
64
|
+
}
|
|
65
|
+
export interface ClonedEntry {
|
|
66
|
+
id: string;
|
|
67
|
+
sha: string;
|
|
68
|
+
path: string;
|
|
69
|
+
coordinate: string;
|
|
70
|
+
visibility: Visibility;
|
|
71
|
+
provenance: Provenance;
|
|
72
|
+
}
|
|
73
|
+
export interface SkippedEntry {
|
|
74
|
+
id: string;
|
|
75
|
+
reason: string;
|
|
76
|
+
}
|
|
77
|
+
export interface NoAccessEntry {
|
|
78
|
+
id: string;
|
|
79
|
+
visibility: Visibility;
|
|
80
|
+
reason: string;
|
|
81
|
+
}
|
|
82
|
+
export interface BucketEntry {
|
|
83
|
+
id: string;
|
|
84
|
+
reason: string;
|
|
85
|
+
}
|
|
86
|
+
/** Structured, --json-serializable clone outcome. Every member lands in one bucket. */
|
|
87
|
+
export interface CloneReport {
|
|
88
|
+
mode: CloneMode;
|
|
89
|
+
credentialsNeeded: number;
|
|
90
|
+
cloned: ClonedEntry[];
|
|
91
|
+
skipped: SkippedEntry[];
|
|
92
|
+
'skipped-no-access': NoAccessEntry[];
|
|
93
|
+
'not-found': BucketEntry[];
|
|
94
|
+
failed: BucketEntry[];
|
|
95
|
+
closureSize: number;
|
|
96
|
+
}
|
|
97
|
+
/** The git surface cloneFromLock depends on; inject a fake for deterministic tests. */
|
|
98
|
+
export interface GitRunner {
|
|
99
|
+
exists(absPath: string): boolean;
|
|
100
|
+
isRepo(absPath: string): boolean;
|
|
101
|
+
clone(cloneUrl: string, absPath: string): void;
|
|
102
|
+
checkout(absPath: string, sha: string): void;
|
|
103
|
+
headSha(absPath: string): string;
|
|
104
|
+
}
|
|
105
|
+
export interface GitLabProject {
|
|
106
|
+
id: number | string;
|
|
107
|
+
path_with_namespace?: string;
|
|
108
|
+
http_url_to_repo?: string;
|
|
109
|
+
visibility?: Visibility;
|
|
110
|
+
default_branch?: string;
|
|
111
|
+
[k: string]: unknown;
|
|
112
|
+
}
|
|
113
|
+
export interface GitLabTag {
|
|
114
|
+
name: string;
|
|
115
|
+
commit?: {
|
|
116
|
+
id?: string;
|
|
117
|
+
sha?: string;
|
|
118
|
+
};
|
|
119
|
+
}
|
|
120
|
+
export interface PackumentVersion {
|
|
121
|
+
dist?: {
|
|
122
|
+
tarball?: string;
|
|
123
|
+
};
|
|
124
|
+
dependencies?: Record<string, string>;
|
|
125
|
+
[k: string]: unknown;
|
|
126
|
+
}
|
|
127
|
+
export interface Packument {
|
|
128
|
+
name?: string;
|
|
129
|
+
'dist-tags'?: {
|
|
130
|
+
latest?: string;
|
|
131
|
+
};
|
|
132
|
+
versions?: Record<string, PackumentVersion>;
|
|
133
|
+
[k: string]: unknown;
|
|
134
|
+
}
|
|
135
|
+
/** Read-only GitLab client; inject a fake in tests. */
|
|
136
|
+
export interface GitLabApi {
|
|
137
|
+
getProject(id: number | string): Promise<GitLabProject>;
|
|
138
|
+
getTags(id: number | string): Promise<GitLabTag[]>;
|
|
139
|
+
getPackument(name: string, opts?: {
|
|
140
|
+
group?: string;
|
|
141
|
+
}): Promise<Packument>;
|
|
142
|
+
}
|
|
143
|
+
/** scope → group (+ optional url) default table. */
|
|
144
|
+
export type RegistryMap = Record<string, {
|
|
145
|
+
group: string;
|
|
146
|
+
url?: string;
|
|
147
|
+
}>;
|
|
148
|
+
/** Install block: channelled ({channel:{name:ver}}) OR a flat {name:ver} map. */
|
|
149
|
+
export type InstallBlock = Record<string, Record<string, string>> | Record<string, string>;
|
|
150
|
+
/** snapshot.json-like input consumed by resolveFromManifest (B2). */
|
|
151
|
+
export interface Manifest {
|
|
152
|
+
name?: string;
|
|
153
|
+
version?: string;
|
|
154
|
+
subset?: string;
|
|
155
|
+
registry?: RegistryMap;
|
|
156
|
+
install?: InstallBlock;
|
|
157
|
+
[k: string]: unknown;
|
|
158
|
+
}
|
|
159
|
+
/** Object form of a skit `dependencies.npm` value (source-pinned). */
|
|
160
|
+
export interface NpmDependencySpec {
|
|
161
|
+
version: string;
|
|
162
|
+
source?: 'npm' | 'proxy';
|
|
163
|
+
}
|
|
164
|
+
/**
|
|
165
|
+
* skit.json (SkitManifest) shape — documented for consumers that map it into a
|
|
166
|
+
* {@link Manifest} before calling resolveFromManifest (a thin per-distribution shim).
|
|
167
|
+
*/
|
|
168
|
+
export interface SkitManifest {
|
|
169
|
+
name: string;
|
|
170
|
+
version: string;
|
|
171
|
+
registry?: RegistryMap;
|
|
172
|
+
dependencies?: {
|
|
173
|
+
npm?: Record<string, string | NpmDependencySpec>;
|
|
174
|
+
skit?: Record<string, string>;
|
|
175
|
+
};
|
|
176
|
+
glpkg?: {
|
|
177
|
+
groups?: Record<string, string[]>;
|
|
178
|
+
policy?: string;
|
|
179
|
+
};
|
|
180
|
+
[k: string]: unknown;
|
|
181
|
+
}
|
|
182
|
+
export interface CloneFromLockOptions {
|
|
183
|
+
mode?: CloneMode;
|
|
184
|
+
dest: string;
|
|
185
|
+
only?: string[];
|
|
186
|
+
installer?: string[];
|
|
187
|
+
git?: GitRunner;
|
|
188
|
+
workspaceDir?: string;
|
|
189
|
+
}
|
|
190
|
+
/** Reader that returns an installed package.json (path-1 manifest-repository). */
|
|
191
|
+
export type ReadInstalledManifest = (name: string) => {
|
|
192
|
+
repository?: unknown;
|
|
193
|
+
[k: string]: unknown;
|
|
194
|
+
} | null;
|
|
195
|
+
export interface ResolveLockOptions {
|
|
196
|
+
packageLockPath: string;
|
|
197
|
+
nodeModulesDir?: string;
|
|
198
|
+
subset: string;
|
|
199
|
+
scopes?: string[];
|
|
200
|
+
source?: Partial<Pick<LockSource, 'manifest' | 'manifestVersion'>> & {
|
|
201
|
+
registry?: Record<string, unknown>;
|
|
202
|
+
};
|
|
203
|
+
api: GitLabApi;
|
|
204
|
+
installer?: string;
|
|
205
|
+
readInstalledManifest?: ReadInstalledManifest;
|
|
206
|
+
now?: () => string;
|
|
207
|
+
warn?: (msg: string) => void;
|
|
208
|
+
}
|
|
209
|
+
export interface ResolveFromManifestOptions {
|
|
210
|
+
api: GitLabApi;
|
|
211
|
+
scopes?: string[];
|
|
212
|
+
subset?: string;
|
|
213
|
+
source?: {
|
|
214
|
+
manifest?: string | null;
|
|
215
|
+
manifestVersion?: string | null;
|
|
216
|
+
};
|
|
217
|
+
readInstalledManifest?: ReadInstalledManifest;
|
|
218
|
+
now?: () => string;
|
|
219
|
+
warn?: (msg: string) => void;
|
|
220
|
+
}
|
|
221
|
+
export interface ResolveResult {
|
|
222
|
+
lock: ResolvedLock;
|
|
223
|
+
warnings: string[];
|
|
224
|
+
}
|
|
225
|
+
//# sourceMappingURL=types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAIH,6EAA6E;AAC7E,MAAM,MAAM,SAAS,GAAG,QAAQ,G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;QAAE,QAAQ,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAA;KAAE,CAAC;IAC5G,GAAG,EAAE,SAAS,CAAC;IACf,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,qBAAqB,CAAC,EAAE,qBAAqB,CAAC;IAC9C,GAAG,CAAC,EAAE,MAAM,MAAM,CAAC;IACnB,IAAI,CAAC,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,IAAI,CAAC;CAC9B;AAED,MAAM,WAAW,0BAA0B;IACzC,GAAG,EAAE,SAAS,CAAC;IACf,MAAM,CAAC,EAAE,MAAM,EAAE,CAAC;IAClB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,MAAM,CAAC,EAAE;QAAE,QAAQ,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;QAAC,eAAe,CAAC,EAAE,MAAM,GAAG,IAAI,CAAA;KAAE,CAAC;IACvE,qBAAqB,CAAC,EAAE,qBAAqB,CAAC;IAC9C,GAAG,CAAC,EAAE,MAAM,MAAM,CAAC;IACnB,IAAI,CAAC,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,IAAI,CAAC;CAC9B;AAED,MAAM,WAAW,aAAa;IAC5B,IAAI,EAAE,YAAY,CAAC;IACnB,QAAQ,EAAE,MAAM,EAAE,CAAC;CACpB"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Public type surface for @gitdot/clone-lib (RESOLVED-LOCK-SPEC S2/S3/S4).
|
|
4
|
+
*
|
|
5
|
+
* Consumers (snapshot / skit / glpkg) import these to type their adapters:
|
|
6
|
+
* import type { ResolvedLock, Member, CloneReport, Manifest } from '@gitdot/clone-lib';
|
|
7
|
+
*/
|
|
8
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
9
|
+
//# sourceMappingURL=types.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":";AAAA;;;;;GAKG"}
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@gitdot/clone-lib",
|
|
3
|
+
"version": "0.2.0",
|
|
4
|
+
"description": "Shared resolved-lock library (TypeScript): resolve a distribution's install closure (from a package-lock or a snapshot.json manifest) into a resolved-lock (RESOLVED-LOCK-SPEC S2), then clone that closure. Zero runtime dependencies.",
|
|
5
|
+
"type": "commonjs",
|
|
6
|
+
"main": "dist/index.js",
|
|
7
|
+
"types": "dist/index.d.ts",
|
|
8
|
+
"exports": {
|
|
9
|
+
".": {
|
|
10
|
+
"types": "./dist/index.d.ts",
|
|
11
|
+
"default": "./dist/index.js"
|
|
12
|
+
},
|
|
13
|
+
"./resolve": {
|
|
14
|
+
"types": "./dist/resolve/index.d.ts",
|
|
15
|
+
"default": "./dist/resolve/index.js"
|
|
16
|
+
},
|
|
17
|
+
"./package.json": "./package.json"
|
|
18
|
+
},
|
|
19
|
+
"bin": {
|
|
20
|
+
"gitdot-resolve": "dist/bin/gitdot-resolve.js"
|
|
21
|
+
},
|
|
22
|
+
"files": [
|
|
23
|
+
"dist",
|
|
24
|
+
"README.md"
|
|
25
|
+
],
|
|
26
|
+
"scripts": {
|
|
27
|
+
"clean": "node -e \"require('fs').rmSync('dist',{recursive:true,force:true})\"",
|
|
28
|
+
"build": "npm run clean && tsc -p tsconfig.json",
|
|
29
|
+
"typecheck": "tsc --noEmit",
|
|
30
|
+
"test": "npm run build && node --test",
|
|
31
|
+
"prepublishOnly": "npm run build"
|
|
32
|
+
},
|
|
33
|
+
"engines": {
|
|
34
|
+
"node": ">=18"
|
|
35
|
+
},
|
|
36
|
+
"keywords": [
|
|
37
|
+
"gitdot",
|
|
38
|
+
"resolved-lock",
|
|
39
|
+
"clone",
|
|
40
|
+
"gitlab",
|
|
41
|
+
"monorepo",
|
|
42
|
+
"typescript"
|
|
43
|
+
],
|
|
44
|
+
"license": "UNLICENSED",
|
|
45
|
+
"repository": {
|
|
46
|
+
"type": "git",
|
|
47
|
+
"url": "git+https://gitlab.com/microwiseai/gitdot.clone-lib.git"
|
|
48
|
+
},
|
|
49
|
+
"devDependencies": {
|
|
50
|
+
"@types/node": "^20.19.43",
|
|
51
|
+
"typescript": "^5.9.3"
|
|
52
|
+
}
|
|
53
|
+
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@microwiseai/snapshot",
|
|
3
|
-
"version": "0.5.
|
|
3
|
+
"version": "0.5.1",
|
|
4
4
|
"description": "CLI for installing IST Snapshot packages",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/lib.js",
|
|
@@ -31,7 +31,8 @@
|
|
|
31
31
|
"files": [
|
|
32
32
|
"dist",
|
|
33
33
|
"node_modules/@microwiseai",
|
|
34
|
-
"node_modules/@ist"
|
|
34
|
+
"node_modules/@ist",
|
|
35
|
+
"node_modules/@gitdot"
|
|
35
36
|
],
|
|
36
37
|
"keywords": [
|
|
37
38
|
"snapshot",
|
|
@@ -65,6 +66,7 @@
|
|
|
65
66
|
"node": ">=18.0.0"
|
|
66
67
|
},
|
|
67
68
|
"bundleDependencies": [
|
|
69
|
+
"@gitdot/clone-lib",
|
|
68
70
|
"@microwiseai/import-telemetry",
|
|
69
71
|
"@microwiseai/license",
|
|
70
72
|
"@microwiseai/skit",
|