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
Use npm commander for parsing argv #24
Comments
looking in app.js further, this would be far more ideal than interacting directly with process.std*, it'd be much more readable. |
Nice -- I was not aware of the commander module. Will integrate for the next release. |
Also worth considering is nconf - it's a bit heavier and lacks the prompting, but provides a mixture of configuration methods. https://github.com/flatiron/nconf That means you'd also have defaults, hierarchies, ENV variables, etc. |
Merged into |
Candidate for Better written as You might as well use both nconf and commander here - specifically here, commander would be the ideal. Relevant: Also look into async.series using an object for storing functions - each function would then be your ask() call, and you'd get away from indent hell that way. Would look far cleaner and easier to read. Look into node-validator / express-validator for a better method of email validation. Rather than defining default configs here, why not do so at the top of the file beside this? Relevant, https://github.com/flatiron/nconf#hierarchical-configuration - look at Other than that, looking like a decent improvement. |
Thanks, Re: indent hell - I've actually taken out all of the nested As for The latest commit has the defaults defined in |
|
@julianlam regarding nconf-redis, that is something of which I am not familiar with. I would suggest asking the developer straight up about the behavior. |
official v1.9.1 merge to paciak release branch
As on tin; would also make creation of a
--help
command much easier and make it a bit easier to determine how to run or configure the application from commandline.The text was updated successfully, but these errors were encountered: