dominictarr / rc

The non-configurable configuration loader for lazy people.
Other
1.02k stars 97 forks source link

Thread minimist argument template #60

Closed kriskowal closed 9 years ago

kriskowal commented 9 years ago

Although this makes the signature teeteringly unwieldy, there’s not much for it without breaking back-compat. Please advise.

dominictarr commented 9 years ago

Can you explain what this does and why you need this? We onlyake changes to rc very reluctantly and its on the requester to make a compelling case.

kriskowal commented 9 years ago

I am hoping to swap minimist for rc in tcurl so I can subvert existing command line options with configuration. In particular, we have a --hostlist option with a -H alias. I would like to be able to thread our existing minimist configuration including aliases through rc so -H would override the hostlist configuration.

I expect minimist defaults to mask configuration, so I intend to evade them.

dominictarr commented 9 years ago

okay that sounds pretty complicated and messy, so I'm not gonna merge this, but it is possible to pass in a custom cli opts parser. You could use this with your custom configured minimist, and then you wont need to change rc.

kriskowal commented 9 years ago

Aye. Going a different way. Thanks!