hereby 1.5.0 → 1.6.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 +3 -1
- package/dist/cli/runner.js +10 -14
- package/dist/cli/utils.js +0 -1
- package/package.json +7 -8
package/README.md
CHANGED
|
@@ -6,6 +6,8 @@
|
|
|
6
6
|
[](https://github.com/jakebailey/hereby/actions/workflows/ci.yml)
|
|
7
7
|
[](https://codecov.io/gh/jakebailey/hereby)
|
|
8
8
|
|
|
9
|
+
> _I hereby declare thee built._
|
|
10
|
+
|
|
9
11
|
`hereby` is a simple task runner.
|
|
10
12
|
|
|
11
13
|
```
|
|
@@ -60,7 +62,7 @@ export const bundle = task({
|
|
|
60
62
|
await execa("esbuild", [
|
|
61
63
|
"--bundle",
|
|
62
64
|
"./out/index.js",
|
|
63
|
-
"--outfile
|
|
65
|
+
"--outfile=./out/bundled.js",
|
|
64
66
|
]);
|
|
65
67
|
},
|
|
66
68
|
});
|
package/dist/cli/runner.js
CHANGED
|
@@ -1,12 +1,10 @@
|
|
|
1
1
|
import assert from "assert";
|
|
2
2
|
import chalk from "chalk";
|
|
3
|
-
import pLimit from "p-limit";
|
|
4
3
|
export class Runner {
|
|
5
|
-
constructor(d
|
|
4
|
+
constructor(d) {
|
|
6
5
|
this._addedTasks = new WeakMap();
|
|
7
6
|
this._errored = false;
|
|
8
7
|
this._startTimes = new WeakMap();
|
|
9
|
-
this._limiter = limiter ?? pLimit(d.numCPUs);
|
|
10
8
|
this._d = d;
|
|
11
9
|
}
|
|
12
10
|
async runTasks(...tasks) {
|
|
@@ -28,17 +26,15 @@ export class Runner {
|
|
|
28
26
|
if (!run) {
|
|
29
27
|
return;
|
|
30
28
|
}
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
}
|
|
41
|
-
});
|
|
29
|
+
try {
|
|
30
|
+
this.onTaskStart(task);
|
|
31
|
+
await run();
|
|
32
|
+
this.onTaskFinish(task);
|
|
33
|
+
}
|
|
34
|
+
catch (e) {
|
|
35
|
+
this.onTaskError(task, e);
|
|
36
|
+
throw e;
|
|
37
|
+
}
|
|
42
38
|
}
|
|
43
39
|
onTaskStart(task) {
|
|
44
40
|
this._startTimes.set(task, Date.now());
|
package/dist/cli/utils.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "hereby",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.6.0",
|
|
4
4
|
"description": "A simple task runner",
|
|
5
5
|
"repository": "github:jakebailey/hereby",
|
|
6
6
|
"type": "module",
|
|
@@ -38,13 +38,12 @@
|
|
|
38
38
|
"./dist/index.d.ts"
|
|
39
39
|
],
|
|
40
40
|
"dependencies": {
|
|
41
|
-
"chalk": "^5.
|
|
41
|
+
"chalk": "^5.1.2",
|
|
42
42
|
"command-line-args": "^5.2.1",
|
|
43
43
|
"command-line-usage": "^6.1.3",
|
|
44
44
|
"fastest-levenshtein": "^1.0.16",
|
|
45
45
|
"foreground-child": "^2.0.0",
|
|
46
46
|
"import-meta-resolve": "^2.1.0",
|
|
47
|
-
"p-limit": "^4.0.0",
|
|
48
47
|
"pretty-ms": "^8.0.0"
|
|
49
48
|
},
|
|
50
49
|
"devDependencies": {
|
|
@@ -52,18 +51,18 @@
|
|
|
52
51
|
"@tsconfig/node14": "^1.0.3",
|
|
53
52
|
"@types/command-line-args": "^5.2.0",
|
|
54
53
|
"@types/command-line-usage": "^5.0.2",
|
|
55
|
-
"@types/node": "^14.18.
|
|
56
|
-
"@typescript-eslint/eslint-plugin": "^5.
|
|
57
|
-
"@typescript-eslint/parser": "^5.
|
|
54
|
+
"@types/node": "^14.18.32",
|
|
55
|
+
"@typescript-eslint/eslint-plugin": "^5.40.0",
|
|
56
|
+
"@typescript-eslint/parser": "^5.40.0",
|
|
58
57
|
"ava": "^4.3.3",
|
|
59
58
|
"c8": "^7.12.0",
|
|
60
59
|
"dprint": "^0.32.1",
|
|
61
|
-
"eslint": "^8.
|
|
60
|
+
"eslint": "^8.25.0",
|
|
62
61
|
"eslint-plugin-ava": "^13.2.0",
|
|
63
62
|
"eslint-plugin-simple-import-sort": "^8.0.0",
|
|
64
63
|
"execa": "^6.1.0",
|
|
65
64
|
"moq.ts": "^9.0.2",
|
|
66
|
-
"release-it": "^15.
|
|
65
|
+
"release-it": "^15.5.0",
|
|
67
66
|
"rimraf": "^3.0.2",
|
|
68
67
|
"tempy": "^3.0.0",
|
|
69
68
|
"typescript": "~4.8.4"
|