license-check-and-add
Version:
A tool to enable the checking, inserting and removal of licenses
27 lines • 1 kB
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
var constants_1 = require("../constants");
var license_manager_1 = require("../lib/license-manager");
var utils_1 = require("./utils");
var ADD_OPTIONS = {
'regex-replacements': {
alias: ['r'],
// tslint:disable-next-line: max-line-length
description: 'Values to use where regex exists in the given license, first value will replace first regex instance and so on. If only one value is supplied this will replace all instances.',
required: false,
type: 'array',
},
};
var cmd = {
builder: function (yargs) {
yargs.options(Object.assign(constants_1.OPTIONS, ADD_OPTIONS));
yargs.usage('license-check-and-add add');
return yargs;
},
command: 'add [options]',
handler: function (args) {
utils_1.manageLicense(args, license_manager_1.ManagementMode.INSERT);
},
};
utils_1.addExports(exports, cmd);
//# sourceMappingURL=add.js.map