-
Notifications
You must be signed in to change notification settings - Fork 2
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
Multi-command #1
Comments
Hey Ryan! Yeah! Within the current setup, it'd be a little more like module.exports = zeroarg({
/**
* one command's help
*/
commandA: function(a, b, c) { ... },
/**
* another command's help
*/
commandB: function(a, b, c) { ... }
}) And zeroarg would know if the module was not the entry point and just be an identity function if not. sub-sub commands... yes if supported by the backend, but afaik yargs doesn't support command nesting, and if commander does, I'm misreading the docs. |
Am I correct that it is important that you bring a function to zeroarg, in order to take advantage of That is, would it need to look like: module.exports = zeroarg(function() {
return {
/**
* one command's help
*/
commandA: function(a, b, c) { ... },
/**
* another command's help
*/
commandB: function(a, b, c) { ... }
};
}); Maybe I just didn't quite understand this:
It does look like yargs has support for sub-command nesting, at least via the |
👋
From ur blog:
Curious how you'd think about structuring this? Something like this?
Would this then support:
Could the nesting go into deeper sub-commands?
The text was updated successfully, but these errors were encountered: