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

have Settings modifiers controlled by .env #20

Open
marc-portier opened this issue Sep 29, 2021 · 1 comment
Open

have Settings modifiers controlled by .env #20

marc-portier opened this issue Sep 29, 2021 · 1 comment
Milestone

Comments

@marc-portier
Copy link
Member

marc-portier commented Sep 29, 2021

  • avoid to have to add modifier --mode flag all the time
  • read pysubyt.modifiers from environment
  • support fallback to .env (include https://pypi.org/project/python-dotenv/)
  • have this not (only) in the __main__() but in the core API so always available --> thus code should go into Settings.__init__() (in pysubyt/api.py) to call load_from_modifiers twice: first with the .env, then with the passed values
  • will need assertion or over-ride in the test-cases though to make sure we have a fixed base for testing not messed up by some casual .env
@marc-portier
Copy link
Member Author

while at it:
the --templates might make for another sensible candidate to be injected via .env

@marc-portier marc-portier changed the title have Settings modifiers controled by .env have Settings modifiers controlled by .env Oct 11, 2021
@laurianvm laurianvm added this to the 0.2. milestone Feb 17, 2022
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