-
Notifications
You must be signed in to change notification settings - Fork 671
feat(cli): do not require config file to run CLI #1743
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
Conversation
Codecov Report
@@ Coverage Diff @@
## main #1743 +/- ##
==========================================
- Coverage 91.97% 91.97% -0.01%
==========================================
Files 76 76
Lines 4737 4759 +22
==========================================
+ Hits 4357 4377 +20
- Misses 380 382 +2
Flags with carried forward coverage won't be shown. Click here to find out more.
|
8884417
to
d0c6005
Compare
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.
Can functional tests be added for this. In particular a functional test that demonstrates it works without a config file? Though I guess that will try to contact https://gitlab.com/
😟
d0c6005
to
e6449d3
Compare
BREAKING CHANGE: A config file is no longer needed to run the CLI. python-gitlab will default to https://gitlab.com with no authentication if there is no config file provided. python-gitlab will now also only look for configuration in the provided PYTHON_GITLAB_CFG path, instead of merging it with user- and system-wide config files. If the environment variable is defined and the file cannot be opened, python-gitlab will now explicitly fail.
e6449d3
to
92a893b
Compare
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 good to me. I wasn't sure if you wanted to merge it or not.
Please merge whenever you are ready.
Thanks.
BREAKING CHANGE: A config file is no longer needed to run
the CLI. python-gitlab will default to https://gitlab.com
with no authentication if there is no config file provided.
python-gitlab will now also only look for configuration
in the provided PYTHON_GITLAB_CFG path, instead of merging
it with user- and system-wide config files. If the
environment variable is defined and the file cannot be
opened, python-gitlab will now explicitly fail.
Needed for #1296