Comparing version 3.3.2 to 3.3.3
@@ -20,2 +20,4 @@ const chalk = require('chalk'); | ||
options.excludeOnly = options.excludeOnly || getArgsForFlag(process.argv, '--exclude-only') || looprc.excludeOnly; | ||
options.excludePattern = | ||
options.excludePattern || getArgsForFlag(process.argv, '--exclude-pattern') || looprc.excludePattern; | ||
options.exitOnAggregateError = | ||
@@ -26,2 +28,4 @@ options.exitOnAggregateError || getArgsForFlag(process.argv, '--exit-on-aggregate-error'); | ||
options.includeOnly = options.includeOnly || getArgsForFlag(process.argv, '--include-only') || looprc.includeOnly; | ||
options.includePattern = | ||
options.includePattern || getArgsForFlag(process.argv, '--include-pattern') || looprc.includePattern; | ||
options.parallel = options.parallel || getFlag(process.argv, '--parallel') || looprc.parallel; | ||
@@ -36,2 +40,7 @@ debug(`executing ${util.inspect(options)} ${process.argv}`); | ||
}); | ||
} else if (options.excludePattern) { | ||
const regexp = new RegExp(options.excludePattern); | ||
dirs = dirs.filter(dir => { | ||
return !regexp.test(path.relative(cwd, dir)); | ||
}); | ||
} | ||
@@ -48,2 +57,7 @@ | ||
).sort(); | ||
} else if (options.includePattern) { | ||
const regexp = new RegExp(options.includePattern); | ||
dirs = dirs.filter(dir => { | ||
return regexp.test(path.relative(cwd, dir)); | ||
}); | ||
} | ||
@@ -50,0 +64,0 @@ |
{ | ||
"name": "loop", | ||
"version": "3.3.2", | ||
"version": "3.3.3", | ||
"description": "loop through commands in fun and amazing ways!", | ||
@@ -42,3 +42,3 @@ "main": "./index.js", | ||
"should": "^13.2.3", | ||
"yargs": "^13.0.0" | ||
"yargs": "^14.0.0" | ||
}, | ||
@@ -53,6 +53,9 @@ "devDependencies": { | ||
"jest": "24.8.0", | ||
"mkdirp": "0.5.1", | ||
"mocha": "6.1.4", | ||
"prettier": "1.18.2", | ||
"pretty-quick": "1.11.1" | ||
"pretty-quick": "1.11.1", | ||
"tmp": "0.1.0", | ||
"which": "1.3.1" | ||
} | ||
} |
@@ -16,4 +16,6 @@ # loop | ||
loop --include-only comma,delimited,list,of,dirs - execute a command against all child dirs, ignoring .looprc, and only including the specified directories | ||
loop --include-pattern 'regexp' - execute a command against all child dirs that match the regular expression | ||
loop --exclude comma,delimited,list,of,dirs - execute a command against all child dirs, excluding the specified directories | ||
loop --exclude-only comma,delimited,list,of,dirs - execute a command against all child dirs, excluding only the specified directories | ||
loop --exclude-pattern 'regexp' - execute a command against all child dirs, excluding directories that match the regular expression | ||
loop --init - creates a .looprc in the current working directory | ||
@@ -20,0 +22,0 @@ |
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
Shell access
Supply chain riskThis module accesses the system shell. Accessing the system shell increases the risk of executing arbitrary code.
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
25668
27
329
190
13
1
+ Addedyargs@14.2.3(transitive)
+ Addedyargs-parser@15.0.3(transitive)
- Removedyargs@13.3.2(transitive)
- Removedyargs-parser@13.1.2(transitive)
Updatedyargs@^14.0.0