Skip to content
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

I've forked/added features to commander, which ones are worth doing pull requests for? #229

Closed
joshacheson opened this issue Jun 25, 2014 · 1 comment

Comments

@joshacheson
Copy link

I have my own fork of this project for a cli I'm putting together.

In my fork I currently have a few new features. They are:

  1. Variadic arguments. Pretty self explanatory... I added argument parsing for variadic arguments using the syntax "command [VARIADIC...]" where the word VARIADIC can be replaced by any string, of course. An array of values are then passed to an action callback in the 2nd to last position, right before the options/self/this reference.

  2. A bootstrap function. This is basically a callback you can optionally add to any instance of command that will run before any sub command's action callback. The purpose of this feature was to have access to parsed args and be able to perform logic with them before the program proceeds further downstream to eventual .action() callbacks. In my case, I used this to create a bottleneck where I can configure my logger before any of the actions for my CLI are performed.

and soon I'll be

  1. slightly altering automatically generated help output to do string padding because i've found misaligned help output at times

If anyone believes it's worth actually putting together pull requests for any of these features please let me know and I will do so as soon as I've got the time.

Cheers

@SomeKittens
Copy link
Collaborator

Hi! I'm the new project maintainer. I'd love to have all three of these as (separate) pull requests. Just make sure they're tested.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants