koatty_cli
Advanced tools
Comparing version 1.6.12 to 1.7.0
@@ -264,5 +264,5 @@ #!/usr/bin/env node | ||
helper.mkDir(APP_PATH + path.sep + 'middleware'); | ||
copyFile('middleware' + path.sep + 'middleware.ts', APP_PATH + path.sep + 'middleware' + path.sep + middleware + 'Mid.ts', { | ||
copyFile('middleware' + path.sep + 'middleware.ts', APP_PATH + path.sep + 'middleware' + path.sep + middleware + '.ts', { | ||
'<Path>': '..', | ||
'<Middleware>': middleware + 'Mid' | ||
'<Middleware>': middleware | ||
}); | ||
@@ -273,3 +273,3 @@ | ||
console.log(); | ||
console.log(' list: [..., "' + middleware + 'Mid"] //加载中间件' + middleware); | ||
console.log(' list: [..., "' + middleware + '"] //加载中间件' + middleware); | ||
console.log(' config: { //中间件配置 '); | ||
@@ -396,2 +396,5 @@ console.log(' ...'); | ||
}); | ||
program.command('ctl <controllerName>').description('add controller').action(function (controller) { | ||
createController(controller); | ||
}); | ||
@@ -402,2 +405,5 @@ //create middleware | ||
}); | ||
program.command('mw <middlewareName>').description('add middleware').action(function (middleware) { | ||
createMiddleware(middleware); | ||
}); | ||
@@ -408,2 +414,5 @@ //create service | ||
}); | ||
program.command('sev <serviceName>').description('add service').action(function (service) { | ||
createService(service); | ||
}); | ||
@@ -414,3 +423,6 @@ //create model | ||
}); | ||
program.command('mo <modelName>').description('add model').action(function (model) { | ||
createModel(model); | ||
}); | ||
program.parse(process.argv); |
{ | ||
"name": "koatty_cli", | ||
"version": "1.6.12", | ||
"version": "1.7.0", | ||
"description": "Koatty command line tool.", | ||
@@ -5,0 +5,0 @@ "scripts": { |
43527
663