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

Configliere::Commandline#dashed_flag_for method is a little wonky #18

Open
kornypoet opened this issue Dec 11, 2012 · 0 comments
Open

Comments

@kornypoet
Copy link
Contributor

If a Settings object is defined with a underscored param, there is no way to recycle this param as a command line option.

#!/usr/bin/env ruby

require 'configliere' ; Settings.use(:commandline)

Settings.define :some_param, default: 'some val'
Settings.resolve!

p Settings.dashed_flag_for :some_param
#=> "--some-param=some val"

Which is only marginally useful because the string it returns does not match my original param definition. What would be great is a method that does this, but without altering the definition, so params can be recycled into another Configliere configured program. Is there some specific use-case for dashed_flag_for?

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

1 participant