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

Disabling/enabling remotes: Issue/5544 #5623

merged 57 commits into from Sep 10, 2019


Copy link

@czoido czoido commented Aug 14, 2019

Changelog: Feature: Add subcommand for enabling and disabling remotes
Docs: conan-io/docs#1392

This PR provides the option to enable or disable remotes with the subcommand. By default all remotes are created with disabled=False and the remotes.json file only adds the information in case disabled=True so the absence of the parameter does not break loading files from previous versions

The use is:

conan remote enable/disable -r remote_name_or_pattern

This way you can have remotes in your remotes.json and skip them for operations such as
search or install without having to remove them. The command works with patterns as well so if you have lots of remotes and you only want to have a couple enabled you can do:

conan remote disable *
conan remote enable remote1
conan remote enable remote2

The default behaviour is that disabled remotes will be omitted for every operation but not for printing the list of remotes with conan remote list also if you try to make an operation with a remote that is in disabled state an error will be raised.

Closes #5544

  • Refer to the issue that supports this Pull Request.
  • If the issue has missing info, explain the purpose/use case/pain/need that covers this Pull Request.
  • I've read the Contributing guide.
  • I've followed the PEP8 style guides for Python code.
  • I've opened another PR in the Conan docs repo to the develop branch, documenting this one.

Note: By default this PR will skip the slower tests and will use a limited set of python versions. Check here how to increase the testing level by writing some tags in the current PR body text.

Copy link

@CLAassistant CLAassistant commented Aug 14, 2019

CLA assistant check
All committers have signed the CLA.

@czoido czoido requested a review from lasote Aug 20, 2019
conans/client/cmd/ Outdated Show resolved Hide resolved
@czoido czoido requested review from lasote and jgsogo Aug 20, 2019
Copy link

@jgsogo jgsogo left a comment

Almost there, just a couple of details

conans/client/cache/ Show resolved Hide resolved
conans/test/functional/command/ Outdated Show resolved Hide resolved
conans/test/functional/command/ Outdated Show resolved Hide resolved
Copy link

@memsharded memsharded left a comment

LGTM, good job!

jgsogo approved these changes Aug 27, 2019
lasote approved these changes Sep 10, 2019
@lasote lasote merged commit 5d785b3 into conan-io:develop Sep 10, 2019
2 checks passed
@lasote lasote removed their assignment Sep 11, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
None yet
None yet
Linked issues

Successfully merging this pull request may close these issues.

5 participants