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

Allow to use it inside Python scripts with declarative sequence of Groups #2

Open
cuducos opened this issue Mar 18, 2020 · 0 comments

Comments

@cuducos
Copy link
Owner

cuducos commented Mar 18, 2020

For example, having this declarative structure: https://github.com/cuducos/bot-followers/blob/64eb67a56a85b0ba00544882c2d95f603aa88636/env.py#L60-L129

We should be able to write a Python-like to start the CLI:

parser = Parser.from_object(settings)  # settings is a Python object (e.g.: a tuple of createnv.parser.Group instances)
Generator(Path(".env"), parser, overwrite, use_default)()
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