uni-run 1.0.4 → 1.0.6
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 +122 -0
- package/dist/app.cjs +60 -0
- package/dist/app.d.mts +1 -0
- package/dist/{index.js → app.mjs} +8 -10
- package/dist/{arg-helper.js → arg-helper.cjs} +44 -31
- package/dist/{arg-helper.d.ts → arg-helper.d.cts} +52 -42
- package/dist/arg-helper.d.mts +121 -0
- package/dist/arg-helper.mjs +93 -0
- package/dist/{arg.js → arg.cjs} +5 -2
- package/dist/{arg.d.ts → arg.d.cts} +95 -77
- package/dist/arg.d.mts +243 -0
- package/dist/arg.mjs +9 -0
- package/dist/{bin.js → bin.cjs} +2 -2
- package/dist/{bin.d.ts → bin.d.cts} +1 -1
- package/dist/bin.d.mts +2 -0
- package/dist/bin.mjs +4 -0
- package/dist/builtin-bin/{Executor.js → Executor.cjs} +5 -2
- package/dist/builtin-bin/{Executor.d.ts → Executor.d.cts} +1 -1
- package/dist/builtin-bin/Executor.d.mts +21 -0
- package/dist/builtin-bin/Executor.mjs +61 -0
- package/dist/builtin-bin/{index.js → index.cjs} +4 -1
- package/dist/builtin-bin/{index.d.ts → index.d.cts} +1 -1
- package/dist/builtin-bin/index.d.mts +3 -0
- package/dist/builtin-bin/index.mjs +94 -0
- package/dist/execution/gitignore.cjs +40 -0
- package/dist/execution/gitignore.d.mts +1 -0
- package/dist/execution/gitignore.mjs +11 -0
- package/dist/execution/{index.js → index.cjs} +47 -8
- package/dist/execution/{index.d.ts → index.d.cts} +3 -1
- package/dist/execution/index.d.mts +15 -0
- package/dist/execution/index.mjs +103 -0
- package/dist/execution/kill-process.cjs +50 -0
- package/dist/execution/{kill-process.d.ts → kill-process.d.cts} +1 -1
- package/dist/execution/kill-process.d.mts +2 -0
- package/dist/execution/{kill-process.js → kill-process.mjs} +4 -7
- package/dist/execution/watcher.cjs +64 -0
- package/dist/execution/watcher.d.mts +6 -0
- package/dist/execution/{watcher.js → watcher.mjs} +8 -11
- package/dist/index.cjs +19 -0
- package/dist/index.d.cts +8 -0
- package/dist/index.d.mts +8 -0
- package/dist/index.mjs +13 -0
- package/dist/lib/colors.cjs +32 -0
- package/dist/lib/colors.d.cts +3 -0
- package/dist/lib/colors.d.mts +3 -0
- package/dist/lib/colors.mjs +4 -0
- package/dist/lib/currentModule.cjs +19 -0
- package/dist/lib/currentModule.d.cts +5 -0
- package/dist/lib/currentModule.d.mts +5 -0
- package/dist/lib/currentModule.mjs +17 -0
- package/dist/utils/debounce.d.mts +1 -0
- package/dist/utils/debounce.mjs +7 -0
- package/package.json +14 -10
- package/dist/execution/gitignore.js +0 -14
- package/dist/lib/colors.d.ts +0 -2
- package/dist/lib/colors.js +0 -4
- /package/dist/{index.d.ts → app.d.cts} +0 -0
- /package/dist/execution/{gitignore.d.ts → gitignore.d.cts} +0 -0
- /package/dist/execution/{watcher.d.ts → watcher.d.cts} +0 -0
- /package/dist/utils/{debounce.js → debounce.cjs} +0 -0
- /package/dist/utils/{debounce.d.ts → debounce.d.cts} +0 -0
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// @ts-nocheck
|
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
+
let currentModule;
|
|
5
|
+
try {
|
|
6
|
+
currentModule = module;
|
|
7
|
+
currentModule = exports;
|
|
8
|
+
currentModule = 'cjs';
|
|
9
|
+
}
|
|
10
|
+
catch (_a) {
|
|
11
|
+
currentModule = 'mjs';
|
|
12
|
+
}
|
|
13
|
+
if (!currentModule) {
|
|
14
|
+
throw new Error('Unkown module System');
|
|
15
|
+
}
|
|
16
|
+
exports.default = {
|
|
17
|
+
isCJS: currentModule === 'cjs',
|
|
18
|
+
isESM: currentModule === 'mjs',
|
|
19
|
+
};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
// @ts-nocheck
|
|
2
|
+
let currentModule;
|
|
3
|
+
try {
|
|
4
|
+
currentModule = module;
|
|
5
|
+
currentModule = exports;
|
|
6
|
+
currentModule = 'cjs';
|
|
7
|
+
}
|
|
8
|
+
catch (_a) {
|
|
9
|
+
currentModule = 'mjs';
|
|
10
|
+
}
|
|
11
|
+
if (!currentModule) {
|
|
12
|
+
throw new Error('Unkown module System');
|
|
13
|
+
}
|
|
14
|
+
export default {
|
|
15
|
+
isCJS: currentModule === 'cjs',
|
|
16
|
+
isESM: currentModule === 'mjs',
|
|
17
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function createDebounce(delay: number): (fn: Function) => void;
|
package/package.json
CHANGED
|
@@ -1,18 +1,21 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "uni-run",
|
|
3
|
+
"version": "1.0.6",
|
|
3
4
|
"description": "Universal Runner for many language",
|
|
4
|
-
"version": "1.0.4",
|
|
5
|
-
"type": "commonjs",
|
|
6
5
|
"scripts": {
|
|
7
|
-
"
|
|
8
|
-
"
|
|
6
|
+
"dev": "npmize dev",
|
|
7
|
+
"build": "npmize build",
|
|
9
8
|
"tsc": "tsc --watch --noEmit",
|
|
10
|
-
"
|
|
11
|
-
"
|
|
9
|
+
"lab": "run ./src/__lab__/index.ts",
|
|
10
|
+
"ts": "tsx --watch ./src/__lab__/index.ts",
|
|
11
|
+
"cjs": "node --watch ./dist/__lab__/index.cjs",
|
|
12
|
+
"mjs": "node --watch ./dist/__lab__/index.mjs"
|
|
12
13
|
},
|
|
14
|
+
"main": "./dist/index.cjs",
|
|
15
|
+
"module": "./dist/index.mjs",
|
|
13
16
|
"bin": {
|
|
14
|
-
"run": "./dist/bin.
|
|
15
|
-
"uni-run": "./dist/bin.
|
|
17
|
+
"run": "./dist/bin.cjs",
|
|
18
|
+
"uni-run": "./dist/bin.cjs"
|
|
16
19
|
},
|
|
17
20
|
"dependencies": {
|
|
18
21
|
"ansi-colors": "^4.1.3",
|
|
@@ -23,8 +26,9 @@
|
|
|
23
26
|
},
|
|
24
27
|
"devDependencies": {
|
|
25
28
|
"@types/cross-spawn": "^6.0.6",
|
|
26
|
-
"@types/node": "^22.5.
|
|
27
|
-
"
|
|
29
|
+
"@types/node": "^22.5.5",
|
|
30
|
+
"npmize": "^1.1.3",
|
|
31
|
+
"typescript": "^5.6.2"
|
|
28
32
|
},
|
|
29
33
|
"repository": {
|
|
30
34
|
"type": "git",
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.default = default_1;
|
|
4
|
-
const fs = require("fs");
|
|
5
|
-
const path = require("path");
|
|
6
|
-
const ignore_1 = require("ignore");
|
|
7
|
-
function default_1(baseDir, extraIgnore = []) {
|
|
8
|
-
const gitignorePath = path.resolve(path.join(baseDir, '.gitignore'));
|
|
9
|
-
const ig = (0, ignore_1.default)({ ignorecase: true }).add(extraIgnore);
|
|
10
|
-
if (fs.existsSync(gitignorePath)) {
|
|
11
|
-
return ig.add(fs.readFileSync(gitignorePath).toString());
|
|
12
|
-
}
|
|
13
|
-
return ig;
|
|
14
|
-
}
|
package/dist/lib/colors.d.ts
DELETED
package/dist/lib/colors.js
DELETED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|