just-scripts 2.6.0 → 2.6.2
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/lib/tasks/cleanTask.d.ts.map +1 -1
- package/lib/tasks/cleanTask.js +1 -6
- package/lib/tasks/cleanTask.js.map +1 -1
- package/package.json +4 -4
- package/src/tasks/cleanTask.ts +7 -12
- package/CHANGELOG.json +0 -2461
- package/CHANGELOG.md +0 -1130
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cleanTask.d.ts","sourceRoot":"","sources":["../../src/tasks/cleanTask.ts"],"names":[],"mappings":"AAEA,OAAO,EAAU,YAAY,
|
|
1
|
+
{"version":3,"file":"cleanTask.d.ts","sourceRoot":"","sources":["../../src/tasks/cleanTask.ts"],"names":[],"mappings":"AAEA,OAAO,EAAU,YAAY,EAAE,MAAM,WAAW,CAAC;AAGjD,MAAM,WAAW,gBAAgB;IAC/B;;;OAGG;IACH,KAAK,CAAC,EAAE,MAAM,EAAE,CAAC;IACjB;;;OAGG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAED,wBAAgB,iBAAiB,IAAI,MAAM,EAAE,CAE5C;AAED,wBAAgB,SAAS,CAAC,OAAO,CAAC,EAAE,gBAAgB,GAAG,YAAY,CAAC;AACpE,2CAA2C;AAC3C,wBAAgB,SAAS,CAAC,KAAK,CAAC,EAAE,MAAM,EAAE,EAAE,KAAK,CAAC,EAAE,MAAM,GAAG,YAAY,CAAC"}
|
package/lib/tasks/cleanTask.js
CHANGED
|
@@ -21,13 +21,8 @@ function cleanTask(pathsOrOptions = {}, limit) {
|
|
|
21
21
|
limit = limit || 5;
|
|
22
22
|
return function clean(done) {
|
|
23
23
|
just_task_1.logger.info(`Removing [${paths.map(p => path.relative(process.cwd(), p)).join(', ')}]`);
|
|
24
|
-
const cleanTasks = paths
|
|
25
|
-
.map(cleanPath => function (cb) {
|
|
24
|
+
const cleanTasks = paths.map(cleanPath => function (cb) {
|
|
26
25
|
fse.remove(cleanPath, cb);
|
|
27
|
-
})
|
|
28
|
-
.concat((cb) => {
|
|
29
|
-
(0, just_task_1.clearCache)();
|
|
30
|
-
cb(null);
|
|
31
26
|
});
|
|
32
27
|
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion
|
|
33
28
|
parallelLimit(cleanTasks, limit, done);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cleanTask.js","sourceRoot":"","sources":["../../src/tasks/cleanTask.ts"],"names":[],"mappings":";;;AAAA,gCAAgC;AAChC,6BAA6B;AAC7B,
|
|
1
|
+
{"version":3,"file":"cleanTask.js","sourceRoot":"","sources":["../../src/tasks/cleanTask.ts"],"names":[],"mappings":";;;AAAA,gCAAgC;AAChC,6BAA6B;AAC7B,yCAAiD;AACjD,oDAAqD;AAerD,SAAgB,iBAAiB;IAC/B,OAAO,CAAC,KAAK,EAAE,MAAM,EAAE,MAAM,EAAE,UAAU,CAAC,CAAC;AAC7C,CAAC;AAFD,8CAEC;AAKD,SAAgB,SAAS,CAAC,iBAA8C,EAAE,EAAE,KAAc;IACxF,IAAI,KAAe,CAAC;IACpB,IAAI,KAAK,CAAC,OAAO,CAAC,cAAc,CAAC,EAAE;QACjC,KAAK,GAAG,cAAc,CAAC;KACxB;SAAM;QACL,KAAK,GAAG,cAAc,CAAC,KAAK,IAAI,iBAAiB,EAAE,CAAC;QACpD,KAAK,GAAG,KAAK,IAAI,cAAc,CAAC,KAAK,CAAC;KACvC;IACD,KAAK,GAAG,KAAK,IAAI,CAAC,CAAC;IAEnB,OAAO,SAAS,KAAK,CAAC,IAAiC;QACrD,kBAAM,CAAC,IAAI,CAAC,aAAa,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,QAAQ,CAAC,OAAO,CAAC,GAAG,EAAE,EAAE,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;QAExF,MAAM,UAAU,GAAG,KAAK,CAAC,GAAG,CAC1B,SAAS,CAAC,EAAE,CACV,UAAU,EAAiC;YACzC,GAAG,CAAC,MAAM,CAAC,SAAS,EAAE,EAAE,CAAC,CAAC;QAC5B,CAAC,CACJ,CAAC;QAEF,oEAAoE;QACpE,aAAa,CAAC,UAAU,EAAE,KAAM,EAAE,IAAI,CAAC,CAAC;IAC1C,CAAC,CAAC;AACJ,CAAC;AAvBD,8BAuBC"}
|
package/package.json
CHANGED
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "just-scripts",
|
|
3
|
-
"version": "2.6.
|
|
3
|
+
"version": "2.6.2",
|
|
4
4
|
"description": "Just Stack Scripts",
|
|
5
|
-
"keywords": [],
|
|
6
5
|
"repository": {
|
|
7
6
|
"type": "git",
|
|
8
7
|
"url": "https://github.com/microsoft/just"
|
|
@@ -10,7 +9,8 @@
|
|
|
10
9
|
"homepage": "https://microsoft.github.io/just/",
|
|
11
10
|
"license": "MIT",
|
|
12
11
|
"author": "",
|
|
13
|
-
"main": "
|
|
12
|
+
"main": "lib/index.js",
|
|
13
|
+
"types": "lib/index.d.ts",
|
|
14
14
|
"bin": {
|
|
15
15
|
"just-scripts": "bin/just-scripts.js"
|
|
16
16
|
},
|
|
@@ -32,7 +32,7 @@
|
|
|
32
32
|
"diff-match-patch": "1.0.5",
|
|
33
33
|
"fs-extra": "^11.0.0",
|
|
34
34
|
"glob": "^7.1.3",
|
|
35
|
-
"just-task": "^1.
|
|
35
|
+
"just-task": "^1.14.1",
|
|
36
36
|
"prompts": "^2.4.0",
|
|
37
37
|
"run-parallel-limit": "^1.0.6",
|
|
38
38
|
"semver": "^7.0.0",
|
package/src/tasks/cleanTask.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as fse from 'fs-extra';
|
|
2
2
|
import * as path from 'path';
|
|
3
|
-
import { logger, TaskFunction
|
|
3
|
+
import { logger, TaskFunction } from 'just-task';
|
|
4
4
|
import parallelLimit = require('run-parallel-limit');
|
|
5
5
|
|
|
6
6
|
export interface CleanTaskOptions {
|
|
@@ -36,17 +36,12 @@ export function cleanTask(pathsOrOptions: string[] | CleanTaskOptions = {}, limi
|
|
|
36
36
|
return function clean(done: (err: Error | null) => void) {
|
|
37
37
|
logger.info(`Removing [${paths.map(p => path.relative(process.cwd(), p)).join(', ')}]`);
|
|
38
38
|
|
|
39
|
-
const cleanTasks = paths
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
)
|
|
46
|
-
.concat((cb: (error: Error | null) => void) => {
|
|
47
|
-
clearCache();
|
|
48
|
-
cb(null);
|
|
49
|
-
});
|
|
39
|
+
const cleanTasks = paths.map(
|
|
40
|
+
cleanPath =>
|
|
41
|
+
function (cb: (error: Error | null) => void) {
|
|
42
|
+
fse.remove(cleanPath, cb);
|
|
43
|
+
},
|
|
44
|
+
);
|
|
50
45
|
|
|
51
46
|
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion
|
|
52
47
|
parallelLimit(cleanTasks, limit!, done);
|