UNPKG

ts-packager

Version:
29 lines 836 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.getCliArgs = void 0; const cli = require("command-line-args"); /** * Get CLI arguments * * @param defaults Environment defaults * @returns Returns a new Environment object of the cli args */ function getCliArgs(defaults) { var _a; const args = cli([ { name: 'config', defaultValue: defaults.config }, { name: 'buildDir', defaultValue: defaults.buildDir } ]); if ((_a = args === null || args === void 0 ? void 0 : args.config) === null || _a === void 0 ? void 0 : _a.includes('jasmine.json')) { args.config = defaults.config; } return args; } exports.getCliArgs = getCliArgs; //# sourceMappingURL=cli.js.map