You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

19 lines
445 B

const path = require('path');
/**
* Resolves the output flag
* @param {args} args - Parsed arguments passed to the CLI
*/
const resolveOutput = (args) => {
const { outputPath } = args;
const finalOptions = {
options: { output: {} },
outputOptions: {},
};
if (outputPath) {
finalOptions.options.output.path = path.resolve(outputPath);
}
return finalOptions;
};
module.exports = resolveOutput;