@pipelab/plugin-system 1.0.0-beta.14 → 1.0.0-beta.15
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/dist/index.cjs +153 -82
- package/dist/index.mjs +125 -54
- package/dist/index.mjs.map +1 -1
- package/package.json +3 -3
package/dist/index.cjs
CHANGED
|
@@ -1588,6 +1588,56 @@ function literal(literal_, message) {
|
|
|
1588
1588
|
}
|
|
1589
1589
|
};
|
|
1590
1590
|
}
|
|
1591
|
+
function looseObject(entries, message) {
|
|
1592
|
+
return {
|
|
1593
|
+
kind: "schema",
|
|
1594
|
+
type: "loose_object",
|
|
1595
|
+
reference: looseObject,
|
|
1596
|
+
expects: "Object",
|
|
1597
|
+
async: false,
|
|
1598
|
+
entries,
|
|
1599
|
+
message,
|
|
1600
|
+
_run(dataset, config2) {
|
|
1601
|
+
const input = dataset.value;
|
|
1602
|
+
if (input && typeof input === "object") {
|
|
1603
|
+
dataset.typed = true;
|
|
1604
|
+
dataset.value = {};
|
|
1605
|
+
for (const key in this.entries) {
|
|
1606
|
+
const value2 = input[key];
|
|
1607
|
+
const valueDataset = this.entries[key]._run({
|
|
1608
|
+
typed: false,
|
|
1609
|
+
value: value2
|
|
1610
|
+
}, config2);
|
|
1611
|
+
if (valueDataset.issues) {
|
|
1612
|
+
const pathItem = {
|
|
1613
|
+
type: "object",
|
|
1614
|
+
origin: "value",
|
|
1615
|
+
input,
|
|
1616
|
+
key,
|
|
1617
|
+
value: value2
|
|
1618
|
+
};
|
|
1619
|
+
for (const issue of valueDataset.issues) {
|
|
1620
|
+
if (issue.path) issue.path.unshift(pathItem);
|
|
1621
|
+
else issue.path = [pathItem];
|
|
1622
|
+
dataset.issues?.push(issue);
|
|
1623
|
+
}
|
|
1624
|
+
if (!dataset.issues) dataset.issues = valueDataset.issues;
|
|
1625
|
+
if (config2.abortEarly) {
|
|
1626
|
+
dataset.typed = false;
|
|
1627
|
+
break;
|
|
1628
|
+
}
|
|
1629
|
+
}
|
|
1630
|
+
if (!valueDataset.typed) dataset.typed = false;
|
|
1631
|
+
if (valueDataset.value !== void 0 || key in input) dataset.value[key] = valueDataset.value;
|
|
1632
|
+
}
|
|
1633
|
+
if (!dataset.issues || !config2.abortEarly) {
|
|
1634
|
+
for (const key in input) if (_isValidObjectKey(input, key) && !(key in this.entries)) dataset.value[key] = input[key];
|
|
1635
|
+
}
|
|
1636
|
+
} else _addIssue(this, "type", dataset, config2);
|
|
1637
|
+
return dataset;
|
|
1638
|
+
}
|
|
1639
|
+
};
|
|
1640
|
+
}
|
|
1591
1641
|
function number(message) {
|
|
1592
1642
|
return {
|
|
1593
1643
|
kind: "schema",
|
|
@@ -2125,6 +2175,18 @@ settingsMigratorInternal.createMigrations({
|
|
|
2125
2175
|
})
|
|
2126
2176
|
]
|
|
2127
2177
|
});
|
|
2178
|
+
const connectionsMigratorInternal = createMigrator();
|
|
2179
|
+
const defaultConnections = connectionsMigratorInternal.createDefault({
|
|
2180
|
+
version: "1.0.0",
|
|
2181
|
+
connections: []
|
|
2182
|
+
});
|
|
2183
|
+
connectionsMigratorInternal.createMigrations({
|
|
2184
|
+
defaultValue: defaultConnections,
|
|
2185
|
+
migrations: [createMigration({
|
|
2186
|
+
version: "1.0.0",
|
|
2187
|
+
up: finalVersion
|
|
2188
|
+
})]
|
|
2189
|
+
});
|
|
2128
2190
|
const fileRepoMigratorInternal = createMigrator();
|
|
2129
2191
|
const defaultFileRepo = fileRepoMigratorInternal.createDefault({
|
|
2130
2192
|
version: "2.0.0",
|
|
@@ -2286,11 +2348,51 @@ const LEGACY_ID_MAP = {
|
|
|
2286
2348
|
};
|
|
2287
2349
|
const getStrictPluginId = (pluginId) => {
|
|
2288
2350
|
if (!pluginId) return pluginId;
|
|
2289
|
-
|
|
2290
|
-
if (pluginId.startsWith("@") || pluginId.includes("/") || pluginId.startsWith("pipelab-plugin-")) return pluginId;
|
|
2291
|
-
const prefixed = `@pipelab/plugin-${pluginId}`;
|
|
2292
|
-
return LEGACY_ID_MAP[prefixed] || prefixed;
|
|
2351
|
+
return LEGACY_ID_MAP[pluginId] || pluginId;
|
|
2293
2352
|
};
|
|
2353
|
+
//#endregion
|
|
2354
|
+
//#region ../../packages/shared/src/save-location.ts
|
|
2355
|
+
const SaveLocationInternalValidator = object({
|
|
2356
|
+
id: string(),
|
|
2357
|
+
project: string(),
|
|
2358
|
+
lastModified: string(),
|
|
2359
|
+
type: literal("internal"),
|
|
2360
|
+
configName: string()
|
|
2361
|
+
});
|
|
2362
|
+
const SaveLocationValidator = union([
|
|
2363
|
+
object({
|
|
2364
|
+
id: string(),
|
|
2365
|
+
project: string(),
|
|
2366
|
+
path: string(),
|
|
2367
|
+
lastModified: string(),
|
|
2368
|
+
type: literal("external"),
|
|
2369
|
+
summary: object({
|
|
2370
|
+
plugins: array(string()),
|
|
2371
|
+
name: string(),
|
|
2372
|
+
description: string()
|
|
2373
|
+
})
|
|
2374
|
+
}),
|
|
2375
|
+
SaveLocationInternalValidator,
|
|
2376
|
+
object({
|
|
2377
|
+
id: string(),
|
|
2378
|
+
project: string(),
|
|
2379
|
+
type: literal("pipelab-cloud")
|
|
2380
|
+
})
|
|
2381
|
+
]);
|
|
2382
|
+
object({
|
|
2383
|
+
version: literal("1.0.0"),
|
|
2384
|
+
data: optional(record(string(), SaveLocationValidator), {})
|
|
2385
|
+
});
|
|
2386
|
+
const FileRepoProjectValidatorV2$1 = object({
|
|
2387
|
+
id: string(),
|
|
2388
|
+
name: string(),
|
|
2389
|
+
description: string()
|
|
2390
|
+
});
|
|
2391
|
+
object({
|
|
2392
|
+
version: literal("2.0.0"),
|
|
2393
|
+
projects: array(FileRepoProjectValidatorV2$1),
|
|
2394
|
+
pipelines: optional(array(SaveLocationValidator), [])
|
|
2395
|
+
});
|
|
2294
2396
|
object({
|
|
2295
2397
|
cacheFolder: string(),
|
|
2296
2398
|
theme: union([literal("light"), literal("dark")]),
|
|
@@ -2442,6 +2544,17 @@ object({
|
|
|
2442
2544
|
})),
|
|
2443
2545
|
isInternalMigrationBannerClosed: optional(boolean(), false)
|
|
2444
2546
|
});
|
|
2547
|
+
const ConnectionValidator = looseObject({
|
|
2548
|
+
id: string(),
|
|
2549
|
+
pluginName: string(),
|
|
2550
|
+
name: string(),
|
|
2551
|
+
createdAt: string(),
|
|
2552
|
+
isDefault: boolean()
|
|
2553
|
+
});
|
|
2554
|
+
object({
|
|
2555
|
+
version: literal("1.0.0"),
|
|
2556
|
+
connections: array(ConnectionValidator)
|
|
2557
|
+
});
|
|
2445
2558
|
//#endregion
|
|
2446
2559
|
//#region ../../node_modules/tslog/dist/esm/prettyLogStyles.js
|
|
2447
2560
|
const prettyLogStyles = {
|
|
@@ -2962,7 +3075,7 @@ const useLogger = () => {
|
|
|
2962
3075
|
const OriginValidator = object({
|
|
2963
3076
|
pluginId: string(),
|
|
2964
3077
|
nodeId: string(),
|
|
2965
|
-
version: pipe(
|
|
3078
|
+
version: optional(pipe(string(), description("Pinned version of the plugin for this block. Falls back to \"latest\" when absent.")))
|
|
2966
3079
|
});
|
|
2967
3080
|
const BlockActionValidatorV1 = object({
|
|
2968
3081
|
type: literal("action"),
|
|
@@ -2975,7 +3088,7 @@ const EditorParamValidatorV3 = union([literal("simple"), literal("editor")]);
|
|
|
2975
3088
|
const BlockActionValidatorV3 = object({
|
|
2976
3089
|
type: literal("action"),
|
|
2977
3090
|
uid: string(),
|
|
2978
|
-
name: pipe(
|
|
3091
|
+
name: optional(pipe(string(), description("A custom name provided by the user"))),
|
|
2979
3092
|
disabled: optional(boolean()),
|
|
2980
3093
|
params: record(string(), object({
|
|
2981
3094
|
editor: EditorParamValidatorV3,
|
|
@@ -45285,35 +45398,6 @@ const createEvent = (event) => {
|
|
|
45285
45398
|
};
|
|
45286
45399
|
};
|
|
45287
45400
|
//#endregion
|
|
45288
|
-
//#region ../../packages/shared/src/save-location.ts
|
|
45289
|
-
const SaveLocationInternalValidator = object({
|
|
45290
|
-
id: string(),
|
|
45291
|
-
project: string(),
|
|
45292
|
-
lastModified: string(),
|
|
45293
|
-
type: literal("internal"),
|
|
45294
|
-
configName: string()
|
|
45295
|
-
});
|
|
45296
|
-
const SaveLocationValidator = union([
|
|
45297
|
-
object({
|
|
45298
|
-
id: string(),
|
|
45299
|
-
project: string(),
|
|
45300
|
-
path: string(),
|
|
45301
|
-
lastModified: string(),
|
|
45302
|
-
type: literal("external"),
|
|
45303
|
-
summary: object({
|
|
45304
|
-
plugins: array(string()),
|
|
45305
|
-
name: string(),
|
|
45306
|
-
description: string()
|
|
45307
|
-
})
|
|
45308
|
-
}),
|
|
45309
|
-
SaveLocationInternalValidator,
|
|
45310
|
-
object({
|
|
45311
|
-
id: string(),
|
|
45312
|
-
project: string(),
|
|
45313
|
-
type: literal("pipelab-cloud")
|
|
45314
|
-
})
|
|
45315
|
-
]);
|
|
45316
|
-
//#endregion
|
|
45317
45401
|
//#region ../../packages/shared/src/websocket.types.ts
|
|
45318
45402
|
var WebSocketError = class extends Error {
|
|
45319
45403
|
constructor(message, code, requestId) {
|
|
@@ -45330,20 +45414,6 @@ object({
|
|
|
45330
45414
|
version: literal("1.0.0"),
|
|
45331
45415
|
data: optional(record(string(), SaveLocationValidator), {})
|
|
45332
45416
|
});
|
|
45333
|
-
const FileRepoProjectValidatorV2$1 = object({
|
|
45334
|
-
id: string(),
|
|
45335
|
-
name: string(),
|
|
45336
|
-
description: string()
|
|
45337
|
-
});
|
|
45338
|
-
object({
|
|
45339
|
-
version: literal("2.0.0"),
|
|
45340
|
-
projects: array(FileRepoProjectValidatorV2$1),
|
|
45341
|
-
pipelines: optional(array(SaveLocationValidator), [])
|
|
45342
|
-
});
|
|
45343
|
-
object({
|
|
45344
|
-
version: literal("1.0.0"),
|
|
45345
|
-
data: optional(record(string(), SaveLocationValidator), {})
|
|
45346
|
-
});
|
|
45347
45417
|
const FileRepoProjectValidatorV2 = object({
|
|
45348
45418
|
id: string(),
|
|
45349
45419
|
name: string(),
|
|
@@ -45355,8 +45425,12 @@ object({
|
|
|
45355
45425
|
pipelines: optional(array(SaveLocationValidator), [])
|
|
45356
45426
|
});
|
|
45357
45427
|
//#endregion
|
|
45428
|
+
//#region ../../packages/constants/src/index.ts
|
|
45429
|
+
const websocketPort = 33753;
|
|
45430
|
+
//#endregion
|
|
45358
45431
|
//#region ../../packages/core-node/src/context.ts
|
|
45359
|
-
const
|
|
45432
|
+
const metaUrl = require("url").pathToFileURL(__filename).href;
|
|
45433
|
+
const _dirname = typeof __dirname !== "undefined" ? __dirname : metaUrl ? (0, node_path.dirname)((0, node_url.fileURLToPath)(metaUrl)) : process.cwd();
|
|
45360
45434
|
const isDev = process.env.NODE_ENV === "development";
|
|
45361
45435
|
/**
|
|
45362
45436
|
* Finds the monorepo root by looking for pnpm-workspace.yaml.
|
|
@@ -48928,9 +49002,6 @@ const useAPI = () => {
|
|
|
48928
49002
|
};
|
|
48929
49003
|
};
|
|
48930
49004
|
//#endregion
|
|
48931
|
-
//#region ../../packages/constants/src/index.ts
|
|
48932
|
-
const websocketPort = 33753;
|
|
48933
|
-
//#endregion
|
|
48934
49005
|
//#region ../../packages/core-node/src/websocket-server.ts
|
|
48935
49006
|
var WebSocketServer = class {
|
|
48936
49007
|
wss = null;
|
|
@@ -53777,14 +53848,14 @@ var require_path_reservations = /* @__PURE__ */ require_chunk.__commonJSMin(((ex
|
|
|
53777
53848
|
const assert$1 = require("assert");
|
|
53778
53849
|
const normalize = require_normalize_unicode();
|
|
53779
53850
|
const stripSlashes = require_strip_trailing_slashes();
|
|
53780
|
-
const { join: join$
|
|
53851
|
+
const { join: join$17 } = require("path");
|
|
53781
53852
|
const isWindows = (process.env.TESTING_TAR_FAKE_PLATFORM || process.platform) === "win32";
|
|
53782
53853
|
module.exports = () => {
|
|
53783
53854
|
const queues = /* @__PURE__ */ new Map();
|
|
53784
53855
|
const reservations = /* @__PURE__ */ new Map();
|
|
53785
53856
|
const getDirs = (path$54) => {
|
|
53786
53857
|
return path$54.split("/").slice(0, -1).reduce((set, path$55) => {
|
|
53787
|
-
if (set.length) path$55 = join$
|
|
53858
|
+
if (set.length) path$55 = join$17(set[set.length - 1], path$55);
|
|
53788
53859
|
set.push(path$55 || "/");
|
|
53789
53860
|
return set;
|
|
53790
53861
|
}, []);
|
|
@@ -53838,7 +53909,7 @@ var require_path_reservations = /* @__PURE__ */ require_chunk.__commonJSMin(((ex
|
|
|
53838
53909
|
};
|
|
53839
53910
|
const reserve = (paths, fn) => {
|
|
53840
53911
|
paths = isWindows ? ["win32 parallelization disabled"] : paths.map((p) => {
|
|
53841
|
-
return stripSlashes(join$
|
|
53912
|
+
return stripSlashes(join$17(normalize(p))).toLowerCase();
|
|
53842
53913
|
});
|
|
53843
53914
|
const dirs = new Set(paths.map((path$59) => getDirs(path$59)).reduce((a, b) => a.concat(b)));
|
|
53844
53915
|
reservations.set(fn, {
|
|
@@ -89489,7 +89560,7 @@ var require_index_min$3 = /* @__PURE__ */ require_chunk.__commonJSMin(((exports)
|
|
|
89489
89560
|
//#region ../../node_modules/@npmcli/promise-spawn/node_modules/which/lib/index.js
|
|
89490
89561
|
var require_lib$27 = /* @__PURE__ */ require_chunk.__commonJSMin(((exports, module) => {
|
|
89491
89562
|
const { isexe, sync: isexeSync } = require_index_min$3();
|
|
89492
|
-
const { join: join$
|
|
89563
|
+
const { join: join$14, delimiter: delimiter$3, sep: sep$4, posix: posix$1 } = require("path");
|
|
89493
89564
|
const isWindows = process.platform === "win32";
|
|
89494
89565
|
/* istanbul ignore next */
|
|
89495
89566
|
const rSlash = new RegExp(`[${posix$1.sep}${sep$4 === posix$1.sep ? "" : sep$4}]`.replace(/(\\)/g, "\\$1"));
|
|
@@ -89519,7 +89590,7 @@ var require_lib$27 = /* @__PURE__ */ require_chunk.__commonJSMin(((exports, modu
|
|
|
89519
89590
|
};
|
|
89520
89591
|
const getPathPart = (raw, cmd) => {
|
|
89521
89592
|
const pathPart = /^".*"$/.test(raw) ? raw.slice(1, -1) : raw;
|
|
89522
|
-
return (!pathPart && rRel.test(cmd) ? cmd.slice(0, 2) : "") + join$
|
|
89593
|
+
return (!pathPart && rRel.test(cmd) ? cmd.slice(0, 2) : "") + join$14(pathPart, cmd);
|
|
89523
89594
|
};
|
|
89524
89595
|
const which = async (cmd, opt = {}) => {
|
|
89525
89596
|
const { pathEnv, pathExt, pathExtExe } = getPathInfo(cmd, opt);
|
|
@@ -90268,7 +90339,7 @@ var require_index_min$2 = /* @__PURE__ */ require_chunk.__commonJSMin(((exports)
|
|
|
90268
90339
|
//#region ../../node_modules/@npmcli/git/node_modules/which/lib/index.js
|
|
90269
90340
|
var require_lib$24 = /* @__PURE__ */ require_chunk.__commonJSMin(((exports, module) => {
|
|
90270
90341
|
const { isexe, sync: isexeSync } = require_index_min$2();
|
|
90271
|
-
const { join: join$
|
|
90342
|
+
const { join: join$13, delimiter: delimiter$2, sep: sep$3, posix } = require("path");
|
|
90272
90343
|
const isWindows = process.platform === "win32";
|
|
90273
90344
|
/* istanbul ignore next */
|
|
90274
90345
|
const rSlash = new RegExp(`[${posix.sep}${sep$3 === posix.sep ? "" : sep$3}]`.replace(/(\\)/g, "\\$1"));
|
|
@@ -90298,7 +90369,7 @@ var require_lib$24 = /* @__PURE__ */ require_chunk.__commonJSMin(((exports, modu
|
|
|
90298
90369
|
};
|
|
90299
90370
|
const getPathPart = (raw, cmd) => {
|
|
90300
90371
|
const pathPart = /^".*"$/.test(raw) ? raw.slice(1, -1) : raw;
|
|
90301
|
-
return (!pathPart && rRel.test(cmd) ? cmd.slice(0, 2) : "") + join$
|
|
90372
|
+
return (!pathPart && rRel.test(cmd) ? cmd.slice(0, 2) : "") + join$13(pathPart, cmd);
|
|
90302
90373
|
};
|
|
90303
90374
|
const which = async (cmd, opt = {}) => {
|
|
90304
90375
|
const { pathEnv, pathExt, pathExtExe } = getPathInfo(cmd, opt);
|
|
@@ -92196,7 +92267,7 @@ var require_lib$22 = /* @__PURE__ */ require_chunk.__commonJSMin(((exports, modu
|
|
|
92196
92267
|
//#endregion
|
|
92197
92268
|
//#region ../../node_modules/npm-normalize-package-bin/lib/index.js
|
|
92198
92269
|
var require_lib$21 = /* @__PURE__ */ require_chunk.__commonJSMin(((exports, module) => {
|
|
92199
|
-
const { join: join$
|
|
92270
|
+
const { join: join$12, basename: basename$4 } = require("path");
|
|
92200
92271
|
const normalize = (pkg) => !pkg.bin ? removeBin(pkg) : typeof pkg.bin === "string" ? normalizeString(pkg) : Array.isArray(pkg.bin) ? normalizeArray(pkg) : typeof pkg.bin === "object" ? normalizeObject(pkg) : removeBin(pkg);
|
|
92201
92272
|
const normalizeString = (pkg) => {
|
|
92202
92273
|
if (!pkg.name) return removeBin(pkg);
|
|
@@ -92219,9 +92290,9 @@ var require_lib$21 = /* @__PURE__ */ require_chunk.__commonJSMin(((exports, modu
|
|
|
92219
92290
|
const clean = {};
|
|
92220
92291
|
let hasBins = false;
|
|
92221
92292
|
Object.keys(orig).forEach((binKey) => {
|
|
92222
|
-
const base = join$
|
|
92293
|
+
const base = join$12("/", basename$4(binKey.replace(/\\|:/g, "/"))).slice(1);
|
|
92223
92294
|
if (typeof orig[binKey] !== "string" || !base) return;
|
|
92224
|
-
const binTarget = join$
|
|
92295
|
+
const binTarget = join$12("/", orig[binKey].replace(/\\/g, "/")).replace(/\\/g, "/").slice(1);
|
|
92225
92296
|
if (!binTarget) return;
|
|
92226
92297
|
clean[base] = binTarget;
|
|
92227
92298
|
hasBins = true;
|
|
@@ -94294,7 +94365,7 @@ var require_polyfill = /* @__PURE__ */ require_chunk.__commonJSMin(((exports, mo
|
|
|
94294
94365
|
const { ERR_FS_CP_DIR_TO_NON_DIR, ERR_FS_CP_EEXIST, ERR_FS_CP_EINVAL, ERR_FS_CP_FIFO_PIPE, ERR_FS_CP_NON_DIR_TO_DIR, ERR_FS_CP_SOCKET, ERR_FS_CP_SYMLINK_TO_SUBDIRECTORY, ERR_FS_CP_UNKNOWN, ERR_FS_EISDIR, ERR_INVALID_ARG_TYPE } = require_errors$3();
|
|
94295
94366
|
const { constants: { errno: { EEXIST, EISDIR, EINVAL, ENOTDIR } } } = require("os");
|
|
94296
94367
|
const { chmod: chmod$2, copyFile, lstat: lstat$2, mkdir: mkdir$7, readdir: readdir$6, readlink, stat: stat$5, symlink, unlink, utimes } = require("fs/promises");
|
|
94297
|
-
const { dirname: dirname$8, isAbsolute: isAbsolute$2, join: join$
|
|
94368
|
+
const { dirname: dirname$8, isAbsolute: isAbsolute$2, join: join$11, parse, resolve: resolve$10, sep: sep$2, toNamespacedPath } = require("path");
|
|
94298
94369
|
const { fileURLToPath } = require("url");
|
|
94299
94370
|
const defaultOptions = {
|
|
94300
94371
|
dereference: false,
|
|
@@ -94503,8 +94574,8 @@ var require_polyfill = /* @__PURE__ */ require_chunk.__commonJSMin(((exports, mo
|
|
|
94503
94574
|
const dir = await readdir$6(src);
|
|
94504
94575
|
for (let i = 0; i < dir.length; i++) {
|
|
94505
94576
|
const item = dir[i];
|
|
94506
|
-
const srcItem = join$
|
|
94507
|
-
const destItem = join$
|
|
94577
|
+
const srcItem = join$11(src, item);
|
|
94578
|
+
const destItem = join$11(dest, item);
|
|
94508
94579
|
const { destStat } = await checkPaths(srcItem, destItem, opts);
|
|
94509
94580
|
await startCopy(destStat, srcItem, destItem, opts);
|
|
94510
94581
|
}
|
|
@@ -94568,13 +94639,13 @@ var require_cp = /* @__PURE__ */ require_chunk.__commonJSMin(((exports, module)
|
|
|
94568
94639
|
//#endregion
|
|
94569
94640
|
//#region ../../node_modules/cacache/node_modules/@npmcli/fs/lib/with-temp-dir.js
|
|
94570
94641
|
var require_with_temp_dir = /* @__PURE__ */ require_chunk.__commonJSMin(((exports, module) => {
|
|
94571
|
-
const { join: join$
|
|
94642
|
+
const { join: join$10, sep: sep$1 } = require("path");
|
|
94572
94643
|
const getOptions = require_get_options();
|
|
94573
94644
|
const { mkdir: mkdir$6, mkdtemp, rm: rm$7 } = require("fs/promises");
|
|
94574
94645
|
const withTempDir = async (root, fn, opts) => {
|
|
94575
94646
|
const options = getOptions(opts, { copy: ["tmpPrefix"] });
|
|
94576
94647
|
await mkdir$6(root, { recursive: true });
|
|
94577
|
-
const target = await mkdtemp(join$
|
|
94648
|
+
const target = await mkdtemp(join$10(`${root}${sep$1}`, options.tmpPrefix || ""));
|
|
94578
94649
|
let err;
|
|
94579
94650
|
let result;
|
|
94580
94651
|
try {
|
|
@@ -94597,10 +94668,10 @@ var require_with_temp_dir = /* @__PURE__ */ require_chunk.__commonJSMin(((export
|
|
|
94597
94668
|
//#region ../../node_modules/cacache/node_modules/@npmcli/fs/lib/readdir-scoped.js
|
|
94598
94669
|
var require_readdir_scoped = /* @__PURE__ */ require_chunk.__commonJSMin(((exports, module) => {
|
|
94599
94670
|
const { readdir: readdir$5 } = require("fs/promises");
|
|
94600
|
-
const { join: join$
|
|
94671
|
+
const { join: join$9 } = require("path");
|
|
94601
94672
|
const readdirScoped = async (dir) => {
|
|
94602
94673
|
const results = [];
|
|
94603
|
-
for (const item of await readdir$5(dir)) if (item.startsWith("@")) for (const scopedItem of await readdir$5(join$
|
|
94674
|
+
for (const item of await readdir$5(dir)) if (item.startsWith("@")) for (const scopedItem of await readdir$5(join$9(dir, item))) results.push(join$9(item, scopedItem));
|
|
94604
94675
|
else results.push(item);
|
|
94605
94676
|
return results;
|
|
94606
94677
|
};
|
|
@@ -94609,7 +94680,7 @@ var require_readdir_scoped = /* @__PURE__ */ require_chunk.__commonJSMin(((expor
|
|
|
94609
94680
|
//#endregion
|
|
94610
94681
|
//#region ../../node_modules/cacache/node_modules/@npmcli/fs/lib/move-file.js
|
|
94611
94682
|
var require_move_file = /* @__PURE__ */ require_chunk.__commonJSMin(((exports, module) => {
|
|
94612
|
-
const { dirname: dirname$7, join: join$
|
|
94683
|
+
const { dirname: dirname$7, join: join$8, resolve: resolve$9, relative: relative$1, isAbsolute: isAbsolute$1 } = require("path");
|
|
94613
94684
|
const fs$12 = require("fs/promises");
|
|
94614
94685
|
const pathExists = async (path$46) => {
|
|
94615
94686
|
try {
|
|
@@ -94634,7 +94705,7 @@ var require_move_file = /* @__PURE__ */ require_chunk.__commonJSMin(((exports, m
|
|
|
94634
94705
|
const sourceStat = await fs$12.lstat(source);
|
|
94635
94706
|
if (sourceStat.isDirectory()) {
|
|
94636
94707
|
const files = await fs$12.readdir(source);
|
|
94637
|
-
await Promise.all(files.map((file) => moveFile(join$
|
|
94708
|
+
await Promise.all(files.map((file) => moveFile(join$8(source, file), join$8(destination, file), options, false, symlinks)));
|
|
94638
94709
|
} else if (sourceStat.isSymbolicLink()) symlinks.push({
|
|
94639
94710
|
source,
|
|
94640
94711
|
destination
|
|
@@ -104173,9 +104244,9 @@ var require_protected = /* @__PURE__ */ require_chunk.__commonJSMin(((exports, m
|
|
|
104173
104244
|
//#region ../../node_modules/pacote/lib/util/cache-dir.js
|
|
104174
104245
|
var require_cache_dir = /* @__PURE__ */ require_chunk.__commonJSMin(((exports, module) => {
|
|
104175
104246
|
const { resolve: resolve$7 } = require("node:path");
|
|
104176
|
-
const { tmpdir
|
|
104247
|
+
const { tmpdir, homedir } = require("node:os");
|
|
104177
104248
|
module.exports = (fakePlatform = false) => {
|
|
104178
|
-
const temp = tmpdir
|
|
104249
|
+
const temp = tmpdir();
|
|
104179
104250
|
const uidOrPid = process.getuid ? process.getuid() : process.pid;
|
|
104180
104251
|
const home = homedir() || resolve$7(temp, "npm-" + uidOrPid);
|
|
104181
104252
|
const platform = fakePlatform || process.platform;
|
|
@@ -105997,7 +106068,7 @@ var require_lib$10 = /* @__PURE__ */ require_chunk.__commonJSMin(((exports, modu
|
|
|
105997
106068
|
var require_lib$9 = /* @__PURE__ */ require_chunk.__commonJSMin(((exports, module) => {
|
|
105998
106069
|
const { Walker: IgnoreWalker } = require_lib$10();
|
|
105999
106070
|
const { lstatSync: lstat$1, readFileSync: readFile$4 } = require("fs");
|
|
106000
|
-
const { basename: basename$2, dirname: dirname$5, extname: extname$1, join: join$
|
|
106071
|
+
const { basename: basename$2, dirname: dirname$5, extname: extname$1, join: join$7, relative, resolve: resolve$6, sep } = require("path");
|
|
106001
106072
|
const { log } = require_lib$29();
|
|
106002
106073
|
const defaultRules = Symbol("npm-packlist.rules.default");
|
|
106003
106074
|
const strictRules = Symbol("npm-packlist.rules.strict");
|
|
@@ -106030,7 +106101,7 @@ var require_lib$9 = /* @__PURE__ */ require_chunk.__commonJSMin(((exports, modul
|
|
|
106030
106101
|
const normalizePath = (path$38) => path$38.split("\\").join("/");
|
|
106031
106102
|
const readOutOfTreeIgnoreFiles = (root, rel, result = []) => {
|
|
106032
106103
|
for (const file of [".npmignore", ".gitignore"]) try {
|
|
106033
|
-
const ignoreContent = readFile$4(join$
|
|
106104
|
+
const ignoreContent = readFile$4(join$7(root, file), { encoding: "utf8" });
|
|
106034
106105
|
result.push(ignoreContent);
|
|
106035
106106
|
break;
|
|
106036
106107
|
} catch (err) {
|
|
@@ -106039,8 +106110,8 @@ var require_lib$9 = /* @__PURE__ */ require_chunk.__commonJSMin(((exports, modul
|
|
|
106039
106110
|
}
|
|
106040
106111
|
if (!rel) return result;
|
|
106041
106112
|
const firstRel = rel.split(sep, 1)[0];
|
|
106042
|
-
const newRoot = join$
|
|
106043
|
-
return readOutOfTreeIgnoreFiles(newRoot, relative(newRoot, join$
|
|
106113
|
+
const newRoot = join$7(root, firstRel);
|
|
106114
|
+
return readOutOfTreeIgnoreFiles(newRoot, relative(newRoot, join$7(root, rel)), result);
|
|
106044
106115
|
};
|
|
106045
106116
|
var PackWalker = class PackWalker extends IgnoreWalker {
|
|
106046
106117
|
constructor(tree, opts) {
|
|
@@ -106107,7 +106178,7 @@ var require_lib$9 = /* @__PURE__ */ require_chunk.__commonJSMin(((exports, modul
|
|
|
106107
106178
|
let ignoreFiles = null;
|
|
106108
106179
|
if (this.tree.workspaces) {
|
|
106109
106180
|
const workspaceDirs = [...this.tree.workspaces.values()].map((dir) => dir.replace(/\\/g, "/"));
|
|
106110
|
-
const entryPath = join$
|
|
106181
|
+
const entryPath = join$7(this.path, entry).replace(/\\/g, "/");
|
|
106111
106182
|
if (workspaceDirs.includes(entryPath)) ignoreFiles = [
|
|
106112
106183
|
defaultRules,
|
|
106113
106184
|
"package.json",
|
|
@@ -106167,7 +106238,7 @@ var require_lib$9 = /* @__PURE__ */ require_chunk.__commonJSMin(((exports, modul
|
|
|
106167
106238
|
if (file.endsWith("/*")) file += "*";
|
|
106168
106239
|
const inverse = `!${file}`;
|
|
106169
106240
|
try {
|
|
106170
|
-
const stat = lstat$1(join$
|
|
106241
|
+
const stat = lstat$1(join$7(this.path, file.replace(/^!+/, "")).replace(/\\/g, "/"));
|
|
106171
106242
|
if (stat.isFile()) {
|
|
106172
106243
|
strict.unshift(inverse);
|
|
106173
106244
|
this.requiredFiles.push(file.startsWith("/") ? file.slice(1) : file);
|
|
@@ -106224,7 +106295,7 @@ var require_lib$9 = /* @__PURE__ */ require_chunk.__commonJSMin(((exports, modul
|
|
|
106224
106295
|
walker.start();
|
|
106225
106296
|
});
|
|
106226
106297
|
const relativeFrom = relative(this.root, walker.path);
|
|
106227
|
-
for (const file of bundled) this.result.add(join$
|
|
106298
|
+
for (const file of bundled) this.result.add(join$7(relativeFrom, file).replace(/\\/g, "/"));
|
|
106228
106299
|
}
|
|
106229
106300
|
}
|
|
106230
106301
|
};
|
|
@@ -144700,7 +144771,7 @@ require_semver();
|
|
|
144700
144771
|
require_lib();
|
|
144701
144772
|
//#endregion
|
|
144702
144773
|
//#region ../../packages/core-node/src/handler-func.ts
|
|
144703
|
-
const { join: join$
|
|
144774
|
+
const { join: join$5 } = node_path.default;
|
|
144704
144775
|
//#endregion
|
|
144705
144776
|
//#region ../../packages/core-node/src/handlers/plugins.ts
|
|
144706
144777
|
const localPluginsMap = /* @__PURE__ */ new Map();
|