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

Interpolation #5

Open
nicola-lunghi opened this issue Jul 9, 2018 · 4 comments
Open

Interpolation #5

nicola-lunghi opened this issue Jul 9, 2018 · 4 comments
Labels

Comments

@nicola-lunghi
Copy link

Hi
is possible to add an option for extended interpolation?
for example:

[common]
proto_dir = /usr/share/bumblebee-protos

[proto.automation]
proto_file = ${common:proto_dir}/automation.proto
@jenisys
Copy link
Collaborator

jenisys commented Jul 16, 2018

Currently, only BasicInterpolation is supported (by looking at the implementation).
You would need to overwrite and reimplement ConfigFileReader.read_config() in a derived class to provide the ConfigParser(interpolation=ExtendedInterpolation()) parameter.

@gilesknap
Copy link

I have created a PR #7 which would allow you to pass any arguments to the ConfigParser constructor. This should resolve this issue and expose all other features of ConfigParser (I use it for inline comments)

@gilesknap
Copy link

@jenisys I'm not sure if you are maintaining this repo any more? Would you be willing to take on an additional developer? I would be happy to contribute if you add me to this repo. Thanks.

@kdeldycke
Copy link

I just release click-extra v1.9.0 which allows by default to load INI configuration files for Click while allowing ExtendedInterpolation by default.

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

Successfully merging a pull request may close this issue.

4 participants