-
Notifications
You must be signed in to change notification settings - Fork 120
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Tower CLI #416
Comments
This would also alleviate a lot of the burden in setting up a new component. We could just a simple command: Again, many of these commands can be deferred to more specialized tools like component-test. |
Yeah that's good, pretty much how it is now. I like the idea of the cookbooks (but probably a better name). It can be accomplished with |
@lancejpollard Working on the cli stuff under @clijs. It'll be extremely easy to start creating the tower cli to generate components and such. var cli = require('tower-cli');
var tower = cli('tower');
var generator = require('tower-generator');
tower.command('create {name}', function(name) {
return generator('./generators/component', process.cwd(), { name: name });
}).then(function(ok) {
cli.success(ok);
}).catch(function(err) {
cli.error(err);
});
var gen = tower.command('generate');
gen.command('model {name}', function(name) {
// Same as the previous generator.
});
gen.command('migration {name}', function(name) {
// Same as the previous generator.
}); These commands can then be run with: tower create foo
tower generate model user
tower generate migration create-user |
Boom! That'll be awesome :) |
Having a Tower CLI in the main repo would be pretty slick. The CLI would simply be a wrapper around component(1) and provide some utilities, such as scaffolding new components/projects, running a server during development, live-reloading, file watching, component builder.
Many people will want to use preprocessors such as Sass, Less, CoffeeScript, etc... so potentially having the ability to easily provide plugins for an entire project would be best.
The text was updated successfully, but these errors were encountered: