Comparing version 3.6.4 to 3.6.5
@@ -106,3 +106,3 @@ "use strict"; | ||
(process.versions.node < '8.0.0' ? process.cwd : process.cwd()), | ||
env: Object.assign(process.env, { FORCE_COLOR: process.stdout.isTTY }), | ||
env: Object.assign(process.env, process.stdout.isTTY ? { FORCE_COLOR: '1' } : {}), | ||
stdio: this.opts.collectLogs || this.opts.prefixer != null || this.opts.doneCriteria | ||
@@ -109,0 +109,0 @@ ? 'pipe' |
@@ -5,4 +5,4 @@ "use strict"; | ||
function fixPaths(workspacePath, packagePath, logLine) { | ||
return logLine.replace(/([^/_0-9a-zA-Z])([-_0-9a-zA-Z.]([^\s/'"*]*[/]){1,})([^/'"*]+)\.[0-9a-zA-Z]{1,6}/, m => { | ||
return m[0] + path.relative(workspacePath, path.resolve(packagePath, m.substr(1))); | ||
return logLine.replace(/([\u001b][^m]*m|[^/_0-9a-zA-Z])(([-_0-9a-zA-Z.]([^\s/'"*]*[/]){1,})([^/'"*]+)\.[0-9a-zA-Z]{1,6})/, (_m, before, file) => { | ||
return before + path.relative(workspacePath, path.resolve(packagePath, file)); | ||
}); | ||
@@ -9,0 +9,0 @@ } |
@@ -5,2 +5,3 @@ "use strict"; | ||
const fix_paths_1 = require("./fix-paths"); | ||
const chalk_1 = require("chalk"); | ||
describe('fix paths', () => { | ||
@@ -27,3 +28,7 @@ it('works', () => { | ||
}); | ||
it('works with color codes', () => { | ||
let res = fix_paths_1.fixPaths('/a/b/c', '/a/b/c/packages/p', 'Testing ' + chalk_1.default.blue('src/test.ts:12')); | ||
expect(res).toEqual('Testing ' + chalk_1.default.blue('packages/p/src/test.ts:12')); | ||
}); | ||
}); | ||
//# sourceMappingURL=fix-paths.spec.js.map |
@@ -15,3 +15,3 @@ #!/usr/bin/env node | ||
}) | ||
.usage('$0 [options] <command> [<arg1> <arg2> ...] ') | ||
.usage('$0 [options] -c <command> [<arg1> <arg2> ...] ') | ||
// Note: these examples are chained here as they do not show up otherwise | ||
@@ -18,0 +18,0 @@ // when the required positional <command> is not specified |
{ | ||
"name": "wsrun", | ||
"version": "3.6.4", | ||
"version": "3.6.5", | ||
"description": "executes commands on packages in parallel, but is aware of the dependencies between them", | ||
@@ -5,0 +5,0 @@ "main": "./build/index.js", |
@@ -8,3 +8,3 @@ # Workspace script runner | ||
``` | ||
wsrun [options] <command> [<arg1> <arg2> ...] | ||
wsrun [options] -c <command> [<arg1> <arg2> ...] | ||
@@ -37,4 +37,3 @@ Mode (choose one): | ||
--version Show version number [boolean] | ||
-c Denotes the end of the package list and the beginning of the command. Can be used | ||
instead of "--" [boolean] | ||
-c Denotes the end of the package list and the beginning of the command. | ||
--concurrency Maximum number of commands to be executed at once [number] | ||
@@ -69,3 +68,3 @@ | ||
`yarn wsrun -p planc --stages --done-criteria='Compilation complete' -r watch` will watch planc deps, | ||
in order, continuing when command outputs "Compilation complete" | ||
in order, continuing when command outputs a line containing "Compilation complete" | ||
@@ -72,0 +71,0 @@ `yarn wsrun --exclude-missing test` will run the test script only on packages that have it |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
88513
27
1134
91
5
2