fyn 1.1.27 → 1.1.30
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/fyn.js +112 -25
- package/package.json +3 -2
package/dist/fyn.js
CHANGED
|
@@ -1599,7 +1599,16 @@ const commands = {
|
|
|
1599
1599
|
alias: ["rum", "r"],
|
|
1600
1600
|
usage: "$0 $1 <command> [-- <args>...]",
|
|
1601
1601
|
exec: async (argv, parsed) => {
|
|
1602
|
-
|
|
1602
|
+
try {
|
|
1603
|
+
return await new FynCli(await pickOptions(argv, parsed.nixClap, !argv.opts.list)).run(argv);
|
|
1604
|
+
} catch (err) {
|
|
1605
|
+
if (err.errno !== undefined) {
|
|
1606
|
+
process.exit(err.errno);
|
|
1607
|
+
} else {
|
|
1608
|
+
logger.error("fyn run caught error without errno", err);
|
|
1609
|
+
process.exit(1);
|
|
1610
|
+
}
|
|
1611
|
+
}
|
|
1603
1612
|
},
|
|
1604
1613
|
options: {
|
|
1605
1614
|
list: {
|
|
@@ -5753,7 +5762,7 @@ const {
|
|
|
5753
5762
|
const {
|
|
5754
5763
|
getDepSection,
|
|
5755
5764
|
makeDepStep
|
|
5756
|
-
} = __webpack_require__("./node_modules/.f/_/@fynpo/base/1.1.
|
|
5765
|
+
} = __webpack_require__("./node_modules/.f/_/@fynpo/base/1.1.12-fynlocal_h/@fynpo/base/dist/index.js");
|
|
5757
5766
|
|
|
5758
5767
|
const xaa = __webpack_require__("./lib/util/xaa.js");
|
|
5759
5768
|
|
|
@@ -8723,7 +8732,7 @@ const {
|
|
|
8723
8732
|
|
|
8724
8733
|
const {
|
|
8725
8734
|
PackageRef
|
|
8726
|
-
} = __webpack_require__("./node_modules/.f/_/@fynpo/base/1.1.
|
|
8735
|
+
} = __webpack_require__("./node_modules/.f/_/@fynpo/base/1.1.12-fynlocal_h/@fynpo/base/dist/index.js");
|
|
8727
8736
|
|
|
8728
8737
|
const WATCH_TIME = 5000; // consider meta cache stale after this much time (30 minutes)
|
|
8729
8738
|
|
|
@@ -9739,7 +9748,7 @@ const {
|
|
|
9739
9748
|
const {
|
|
9740
9749
|
FynpoConfigManager,
|
|
9741
9750
|
FynpoDepGraph
|
|
9742
|
-
} = __webpack_require__("./node_modules/.f/_/@fynpo/base/1.1.
|
|
9751
|
+
} = __webpack_require__("./node_modules/.f/_/@fynpo/base/1.1.12-fynlocal_h/@fynpo/base/dist/index.js");
|
|
9743
9752
|
/* eslint-disable no-magic-numbers, max-statements, no-empty, complexity, no-eval */
|
|
9744
9753
|
|
|
9745
9754
|
|
|
@@ -11237,7 +11246,7 @@ module.exports = __webpack_require__("./node_modules/.f/_/xaa/1.7.0/xaa/dist/xaa
|
|
|
11237
11246
|
|
|
11238
11247
|
/***/ }),
|
|
11239
11248
|
|
|
11240
|
-
/***/ "./node_modules/.f/_/@fynpo/base/1.1.
|
|
11249
|
+
/***/ "./node_modules/.f/_/@fynpo/base/1.1.12-fynlocal_h/@fynpo/base/dist/caching.js":
|
|
11241
11250
|
/***/ ((__unused_webpack_module, exports, __webpack_require__) => {
|
|
11242
11251
|
|
|
11243
11252
|
"use strict";
|
|
@@ -11257,6 +11266,8 @@ const lodash_1 = (0, tslib_1.__importDefault)(__webpack_require__("./node_module
|
|
|
11257
11266
|
const fs_1 = (0, tslib_1.__importDefault)(__webpack_require__("fs"));
|
|
11258
11267
|
const path_1 = (0, tslib_1.__importDefault)(__webpack_require__("path"));
|
|
11259
11268
|
const crypto_1 = (0, tslib_1.__importDefault)(__webpack_require__("crypto"));
|
|
11269
|
+
|
|
11270
|
+
const minimatch_group_1 = __webpack_require__("./node_modules/.f/_/@fynpo/base/1.1.12-fynlocal_h/@fynpo/base/dist/minimatch-group.js");
|
|
11260
11271
|
/**
|
|
11261
11272
|
* create a sha256 hash for some data
|
|
11262
11273
|
*
|
|
@@ -11264,6 +11275,7 @@ const crypto_1 = (0, tslib_1.__importDefault)(__webpack_require__("crypto"));
|
|
|
11264
11275
|
* @returns
|
|
11265
11276
|
*/
|
|
11266
11277
|
|
|
11278
|
+
|
|
11267
11279
|
function hashData1(data, encoding = "base64url") {
|
|
11268
11280
|
return crypto_1.default.createHash("sha256").update(data).digest(encoding);
|
|
11269
11281
|
}
|
|
@@ -11366,14 +11378,39 @@ async function scanFiles(cwd, includes, excludes) {
|
|
|
11366
11378
|
return true;
|
|
11367
11379
|
};
|
|
11368
11380
|
|
|
11381
|
+
const dirIncludes = includes.map(mx => (0, minimatch_group_1.deconstructMM)(mx));
|
|
11382
|
+
|
|
11383
|
+
const filterDir = (_file, _path, extras) => {
|
|
11384
|
+
const inc = dirIncludes.find(di => checkMmMatch(extras.dirFile, di.mms));
|
|
11385
|
+
|
|
11386
|
+
if (!inc) {
|
|
11387
|
+
return false;
|
|
11388
|
+
}
|
|
11389
|
+
|
|
11390
|
+
const exc = checkMmMatch(extras.dirFile, excludes);
|
|
11391
|
+
|
|
11392
|
+
if (exc) {
|
|
11393
|
+
return false;
|
|
11394
|
+
}
|
|
11395
|
+
|
|
11396
|
+
return true;
|
|
11397
|
+
};
|
|
11398
|
+
|
|
11369
11399
|
return (await (0, filter_scan_dir_1.filterScanDir)({
|
|
11370
11400
|
cwd,
|
|
11371
11401
|
filter,
|
|
11372
|
-
filterDir
|
|
11402
|
+
filterDir,
|
|
11373
11403
|
fullStat: false,
|
|
11374
11404
|
concurrency: 500
|
|
11375
11405
|
})).sort();
|
|
11376
11406
|
}
|
|
11407
|
+
/**
|
|
11408
|
+
* process caching input rules and return result from it
|
|
11409
|
+
*
|
|
11410
|
+
* @param param0
|
|
11411
|
+
* @returns result from processing input rules
|
|
11412
|
+
*/
|
|
11413
|
+
|
|
11377
11414
|
|
|
11378
11415
|
async function processInput({
|
|
11379
11416
|
cwd,
|
|
@@ -11383,14 +11420,14 @@ async function processInput({
|
|
|
11383
11420
|
} = {
|
|
11384
11421
|
input: {}
|
|
11385
11422
|
}) {
|
|
11386
|
-
const files = await scanFiles(cwd, makeMmPatterns(input.include), makeMmPatterns(input.exclude));
|
|
11423
|
+
const files = await scanFiles(cwd, makeMmPatterns(input.include, input.minimatchOptions), makeMmPatterns(input.exclude, input.minimatchOptions));
|
|
11387
11424
|
const fileHashes = await hashFiles(cwd, files);
|
|
11388
11425
|
const data = {
|
|
11389
11426
|
env: lodash_1.default.pick(process.env, input.includeEnv),
|
|
11390
11427
|
versions: lodash_1.default.pick(process.versions, input.includeVersions),
|
|
11391
11428
|
npmScripts: lodash_1.default.pick(lodash_1.default.get(packageJson || (await readPackageJson(cwd)), "scripts"), input.npmScripts),
|
|
11392
11429
|
fileHashes,
|
|
11393
|
-
extra: extra ||
|
|
11430
|
+
extra: extra || {} // additional data
|
|
11394
11431
|
|
|
11395
11432
|
};
|
|
11396
11433
|
const hash = hashData(JSON.stringify(data));
|
|
@@ -11403,6 +11440,7 @@ async function processInput({
|
|
|
11403
11440
|
|
|
11404
11441
|
exports.processInput = processInput;
|
|
11405
11442
|
/**
|
|
11443
|
+
* process lifecycle caching input rules
|
|
11406
11444
|
*
|
|
11407
11445
|
* @param param0
|
|
11408
11446
|
* @returns
|
|
@@ -11431,7 +11469,7 @@ async function processLifecycleInput({
|
|
|
11431
11469
|
|
|
11432
11470
|
exports.processLifecycleInput = processLifecycleInput;
|
|
11433
11471
|
/**
|
|
11434
|
-
* Process build cache output
|
|
11472
|
+
* Process build cache output rules.
|
|
11435
11473
|
*
|
|
11436
11474
|
* @param param0
|
|
11437
11475
|
* @returns
|
|
@@ -11446,8 +11484,8 @@ async function processOutput({
|
|
|
11446
11484
|
} = {
|
|
11447
11485
|
output: {}
|
|
11448
11486
|
}) {
|
|
11449
|
-
const mmIncludes = makeMmPatterns(output.include);
|
|
11450
|
-
const mmExcludes = makeMmPatterns(output.exclude);
|
|
11487
|
+
const mmIncludes = makeMmPatterns(output.include, output.minimatchOptions);
|
|
11488
|
+
const mmExcludes = makeMmPatterns(output.exclude, output.minimatchOptions);
|
|
11451
11489
|
const files = await scanFiles(cwd, mmIncludes, mmExcludes);
|
|
11452
11490
|
preFiles = [].concat(preFiles).filter(x => {
|
|
11453
11491
|
if (!x || checkMmMatch(x, mmExcludes)) {
|
|
@@ -11487,7 +11525,7 @@ exports.processOutput = processOutput;
|
|
|
11487
11525
|
|
|
11488
11526
|
/***/ }),
|
|
11489
11527
|
|
|
11490
|
-
/***/ "./node_modules/.f/_/@fynpo/base/1.1.
|
|
11528
|
+
/***/ "./node_modules/.f/_/@fynpo/base/1.1.12-fynlocal_h/@fynpo/base/dist/fynpo-config.js":
|
|
11491
11529
|
/***/ ((__unused_webpack_module, exports, __webpack_require__) => {
|
|
11492
11530
|
|
|
11493
11531
|
"use strict";
|
|
@@ -11637,7 +11675,7 @@ exports.FynpoConfigManager = FynpoConfigManager;
|
|
|
11637
11675
|
|
|
11638
11676
|
/***/ }),
|
|
11639
11677
|
|
|
11640
|
-
/***/ "./node_modules/.f/_/@fynpo/base/1.1.
|
|
11678
|
+
/***/ "./node_modules/.f/_/@fynpo/base/1.1.12-fynlocal_h/@fynpo/base/dist/fynpo-dep-graph.js":
|
|
11641
11679
|
/***/ ((__unused_webpack_module, exports, __webpack_require__) => {
|
|
11642
11680
|
|
|
11643
11681
|
"use strict";
|
|
@@ -11667,9 +11705,9 @@ const minimatch_1 = (0, tslib_1.__importDefault)(__webpack_require__("./node_mod
|
|
|
11667
11705
|
const lodash_1 = (0, tslib_1.__importDefault)(__webpack_require__("./node_modules/.f/_/lodash/4.17.21/lodash/lodash.min.js"));
|
|
11668
11706
|
const semver_1 = (0, tslib_1.__importDefault)(__webpack_require__("./node_modules/.f/_/semver/7.3.5/semver/index.js"));
|
|
11669
11707
|
|
|
11670
|
-
const minimatch_group_1 = __webpack_require__("./node_modules/.f/_/@fynpo/base/1.1.
|
|
11708
|
+
const minimatch_group_1 = __webpack_require__("./node_modules/.f/_/@fynpo/base/1.1.12-fynlocal_h/@fynpo/base/dist/minimatch-group.js");
|
|
11671
11709
|
|
|
11672
|
-
const util_1 = __webpack_require__("./node_modules/.f/_/@fynpo/base/1.1.
|
|
11710
|
+
const util_1 = __webpack_require__("./node_modules/.f/_/@fynpo/base/1.1.12-fynlocal_h/@fynpo/base/dist/util.js");
|
|
11673
11711
|
|
|
11674
11712
|
const is_path_inside_1 = (0, tslib_1.__importDefault)(__webpack_require__("./node_modules/.f/_/is-path-inside/3.0.3/is-path-inside/index.js"));
|
|
11675
11713
|
const DepSectionMap = {
|
|
@@ -12390,7 +12428,7 @@ exports.FynpoDepGraph = FynpoDepGraph;
|
|
|
12390
12428
|
|
|
12391
12429
|
/***/ }),
|
|
12392
12430
|
|
|
12393
|
-
/***/ "./node_modules/.f/_/@fynpo/base/1.1.
|
|
12431
|
+
/***/ "./node_modules/.f/_/@fynpo/base/1.1.12-fynlocal_h/@fynpo/base/dist/index.js":
|
|
12394
12432
|
/***/ ((__unused_webpack_module, exports, __webpack_require__) => {
|
|
12395
12433
|
|
|
12396
12434
|
"use strict";
|
|
@@ -12412,12 +12450,12 @@ const filter_scan_dir_1 = __webpack_require__("./node_modules/.f/_/filter-scan-d
|
|
|
12412
12450
|
const minimatch_1 = (0, tslib_1.__importDefault)(__webpack_require__("./node_modules/.f/_/minimatch/3.0.4/minimatch/minimatch.js"));
|
|
12413
12451
|
const lodash_1 = (0, tslib_1.__importDefault)(__webpack_require__("./node_modules/.f/_/lodash/4.17.21/lodash/lodash.min.js"));
|
|
12414
12452
|
|
|
12415
|
-
const minimatch_group_1 = __webpack_require__("./node_modules/.f/_/@fynpo/base/1.1.
|
|
12453
|
+
const minimatch_group_1 = __webpack_require__("./node_modules/.f/_/@fynpo/base/1.1.12-fynlocal_h/@fynpo/base/dist/minimatch-group.js");
|
|
12416
12454
|
|
|
12417
|
-
(0, tslib_1.__exportStar)(__webpack_require__("./node_modules/.f/_/@fynpo/base/1.1.
|
|
12418
|
-
(0, tslib_1.__exportStar)(__webpack_require__("./node_modules/.f/_/@fynpo/base/1.1.
|
|
12419
|
-
(0, tslib_1.__exportStar)(__webpack_require__("./node_modules/.f/_/@fynpo/base/1.1.
|
|
12420
|
-
exports.caching = (0, tslib_1.__importStar)(__webpack_require__("./node_modules/.f/_/@fynpo/base/1.1.
|
|
12455
|
+
(0, tslib_1.__exportStar)(__webpack_require__("./node_modules/.f/_/@fynpo/base/1.1.12-fynlocal_h/@fynpo/base/dist/fynpo-dep-graph.js"), exports);
|
|
12456
|
+
(0, tslib_1.__exportStar)(__webpack_require__("./node_modules/.f/_/@fynpo/base/1.1.12-fynlocal_h/@fynpo/base/dist/fynpo-config.js"), exports);
|
|
12457
|
+
(0, tslib_1.__exportStar)(__webpack_require__("./node_modules/.f/_/@fynpo/base/1.1.12-fynlocal_h/@fynpo/base/dist/util.js"), exports);
|
|
12458
|
+
exports.caching = (0, tslib_1.__importStar)(__webpack_require__("./node_modules/.f/_/@fynpo/base/1.1.12-fynlocal_h/@fynpo/base/dist/caching.js"));
|
|
12421
12459
|
/**
|
|
12422
12460
|
* Take an array of packages and figure out their dependencies on each other
|
|
12423
12461
|
*
|
|
@@ -12673,8 +12711,8 @@ exports.makePkgDeps = makePkgDeps;
|
|
|
12673
12711
|
|
|
12674
12712
|
/***/ }),
|
|
12675
12713
|
|
|
12676
|
-
/***/ "./node_modules/.f/_/@fynpo/base/1.1.
|
|
12677
|
-
/***/ ((__unused_webpack_module, exports) => {
|
|
12714
|
+
/***/ "./node_modules/.f/_/@fynpo/base/1.1.12-fynlocal_h/@fynpo/base/dist/minimatch-group.js":
|
|
12715
|
+
/***/ ((__unused_webpack_module, exports, __webpack_require__) => {
|
|
12678
12716
|
|
|
12679
12717
|
"use strict";
|
|
12680
12718
|
|
|
@@ -12682,7 +12720,11 @@ exports.makePkgDeps = makePkgDeps;
|
|
|
12682
12720
|
Object.defineProperty(exports, "__esModule", ({
|
|
12683
12721
|
value: true
|
|
12684
12722
|
}));
|
|
12685
|
-
exports.groupMM = void 0;
|
|
12723
|
+
exports.deconstructMM = exports.groupMM = void 0;
|
|
12724
|
+
|
|
12725
|
+
const tslib_1 = __webpack_require__("./node_modules/.f/_/tslib/2.1.0/tslib/tslib.es6.js");
|
|
12726
|
+
|
|
12727
|
+
const minimatch_1 = (0, tslib_1.__importDefault)(__webpack_require__("./node_modules/.f/_/minimatch/3.0.4/minimatch/minimatch.js"));
|
|
12686
12728
|
/**
|
|
12687
12729
|
* process a list of minimatch objects and group them by the string prefix of their patterns
|
|
12688
12730
|
*
|
|
@@ -12716,10 +12758,55 @@ function groupMM(mms, groups) {
|
|
|
12716
12758
|
}
|
|
12717
12759
|
|
|
12718
12760
|
exports.groupMM = groupMM;
|
|
12761
|
+
/**
|
|
12762
|
+
* process a minimatch pattern to group them for matching directories
|
|
12763
|
+
*
|
|
12764
|
+
* - needs to create a new pattern at every non-string part
|
|
12765
|
+
* @param pattern
|
|
12766
|
+
*/
|
|
12767
|
+
|
|
12768
|
+
function deconstructMM(m0) {
|
|
12769
|
+
const mms = [];
|
|
12770
|
+
const patterns = {
|
|
12771
|
+
m0,
|
|
12772
|
+
mms
|
|
12773
|
+
};
|
|
12774
|
+
const set = m0.set[0];
|
|
12775
|
+
const globParts = m0.globParts[0];
|
|
12776
|
+
const iParts = [];
|
|
12777
|
+
const {
|
|
12778
|
+
GLOBSTAR
|
|
12779
|
+
} = minimatch_1.default;
|
|
12780
|
+
|
|
12781
|
+
for (let ix = 0; ix < set.length - 1; ix++) {
|
|
12782
|
+
const s = set[ix];
|
|
12783
|
+
const g = globParts[ix];
|
|
12784
|
+
|
|
12785
|
+
if (typeof s !== "string" && s !== GLOBSTAR && iParts.length > 0) {
|
|
12786
|
+
mms.push(new minimatch_1.default.Minimatch(iParts.join("/"), m0.options));
|
|
12787
|
+
}
|
|
12788
|
+
|
|
12789
|
+
iParts.push(g);
|
|
12790
|
+
|
|
12791
|
+
if (typeof s !== "string") {
|
|
12792
|
+
mms.push(new minimatch_1.default.Minimatch(iParts.join("/"), m0.options));
|
|
12793
|
+
} // a pattern ending in GLOBSTAR will match anything
|
|
12794
|
+
|
|
12795
|
+
|
|
12796
|
+
if (s === GLOBSTAR) {
|
|
12797
|
+
return patterns;
|
|
12798
|
+
}
|
|
12799
|
+
}
|
|
12800
|
+
|
|
12801
|
+
mms.push(m0);
|
|
12802
|
+
return patterns;
|
|
12803
|
+
}
|
|
12804
|
+
|
|
12805
|
+
exports.deconstructMM = deconstructMM;
|
|
12719
12806
|
|
|
12720
12807
|
/***/ }),
|
|
12721
12808
|
|
|
12722
|
-
/***/ "./node_modules/.f/_/@fynpo/base/1.1.
|
|
12809
|
+
/***/ "./node_modules/.f/_/@fynpo/base/1.1.12-fynlocal_h/@fynpo/base/dist/util.js":
|
|
12723
12810
|
/***/ ((__unused_webpack_module, exports, __webpack_require__) => {
|
|
12724
12811
|
|
|
12725
12812
|
"use strict";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "fyn",
|
|
3
|
-
"version": "1.1.
|
|
3
|
+
"version": "1.1.30",
|
|
4
4
|
"description": "The package manager for fynpo, a zero setup monorepo manager",
|
|
5
5
|
"main": "./bin/fyn.js",
|
|
6
6
|
"homepage": "https://jchip.github.io/fynpo/",
|
|
@@ -15,7 +15,8 @@
|
|
|
15
15
|
"ci:check": "xrun xarc/check",
|
|
16
16
|
"coveralls": "cat coverage/lcov.info | coveralls",
|
|
17
17
|
"prepublishOnly": "xrun build",
|
|
18
|
-
"postpack": "publish-util-postpack"
|
|
18
|
+
"postpack": "publish-util-postpack",
|
|
19
|
+
"blah": "exit 5"
|
|
19
20
|
},
|
|
20
21
|
"bin": {
|
|
21
22
|
"0-npx-please-run-this-for-fyn": "./bin/fyn.js",
|