-
-
Notifications
You must be signed in to change notification settings - Fork 76
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
Add support for configuration inside 'setup.cfg' #161
Conversation
1 similar comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great start!
To change:
setup.cfg
should come first in the list, because we traverse the config file list in order and each later file overrides earlier files, which unintuitively means that the later an item is in the list, the more important it is.setup.cfg
should be lower priority, so it should come earlier in the list.
To add:
- The documentation for config files needs to be updated in
green/config.py
.setup.cfg
should be the new item 3, with existing items 3-5 becoming 4-6. - Tests! Where are the tests?! ;-)
Also...I wonder if we should change our config-file resolution behavior from merge-all to "first config wins..." Something to ponder. |
I've been pondering it. I like the current merging-of-configs behavior, I think. By the way, if you feel like you need some help with my review suggestions, let me know and (I think) I can make a PR to your PR adding some of the stuff. If that helps. |
Merging is okay, this allows changing some things locally while having a global configuration that is used everywhere, both of which can be updated independantly. I do not agree with EDIT: Oh, I see what you mean, not absolute first but just come before |
Yes, I meant switch it with |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks great!
Included in just-released version 2.9.0. |
While I am at it, I added support for green configuration inside
setup.cfg
, since there seem to be an almost official agreement about using this file for Python dev tools configuration.setup.cfg
is the only file where the[green]
section is expected.