import cliparse from 'cliparse'; import build from '../webpackRunner'; const buildCMD = cliparse.command('build', { description: 'Build all your static assets using Webpack', options: [ cliparse.flag('watch', { aliases: ['w'], description: 'Enable auto watch of js files', }), ], }, build); export default buildCMD;
console.log(message); } function addModule(params) { } const cliParser = cliparse.cli({ name: "philos", description: "Philos CLI tools for managing projects", commands: [ cliparse.command( "echo", { description: "Display the given value", args: [ cliparse.argument("value", { description: "Simple value" })], options: [ cliparse.flag("reverse", { aliases: ["r"], description: "Reverse the value"}) ] }, echoModule), cliparse.command( "add2", { description: "Add 2 to the given integer and display the result", args: [ cliparse.argument("int", { default: 0, parser: parsers.intParser, description: "Int to add 2 to" }) ] }, addModule) ]