mirror of
https://github.com/apache/cordova-android.git
synced 2026-04-23 00:00:09 +08:00
Lint JS files w/out extension too (#453)
Prior to this change, JS files without extension had not been linted. To match them, we need a combination of positive and negative globbing that does not mix well with the existing file selection for linting. Thus, we use npm-run-all to run two ESLint invocations unconditionally in sequence while still preserving the error code. * Lint JS w/out extension too * Fix newly surfaced linting errors * Make use of npm-run-all for test script too
This commit is contained in:
committed by
GitHub
parent
2c3db19310
commit
393dad6349
@@ -19,23 +19,23 @@
|
||||
under the License.
|
||||
*/
|
||||
|
||||
var device = require('./device'),
|
||||
args = process.argv;
|
||||
var device = require('./device');
|
||||
var args = process.argv;
|
||||
|
||||
if(args.length > 2) {
|
||||
if (args.length > 2) {
|
||||
var install_target;
|
||||
if (args[2].substring(0, 9) == '--target=') {
|
||||
if (args[2].substring(0, 9) === '--target=') {
|
||||
install_target = args[2].substring(9, args[2].length);
|
||||
device.install(install_target).done(null, function(err) {
|
||||
device.install(install_target).done(null, function (err) {
|
||||
console.error('ERROR: ' + err);
|
||||
process.exit(2);
|
||||
});
|
||||
} else {
|
||||
} else {
|
||||
console.error('ERROR : argument \'' + args[2] + '\' not recognized.');
|
||||
process.exit(2);
|
||||
}
|
||||
}
|
||||
} else {
|
||||
device.install().done(null, function(err) {
|
||||
device.install().done(null, function (err) {
|
||||
console.error('ERROR: ' + err);
|
||||
process.exit(2);
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user