pipenv
pipenv copied to clipboard
Feature request: allow specifying that packages matching *something* should be downloaded from a secondary index
For our company, all private packages look like companyname-packagename
. It would be cool if there were a way to specify that all packages that start with companyname-
would be downloaded from a specific secondary index instead of the primary index. For packages that rely on other private packages, we currently have to mention to pipenv that those also come from the private repo explicitly.
Not sure if it would be best to allow specifying a regex or just (one or more) prefix strings.
Eg.
[[source]]
url = "https://pypi.org/simple"
verify_ssl = true
name = "pypi"
[[source]]
url = "..."
verify_ssl = true
name = "company-pypi"
default_for = "companyname-.*"
# or just
default_for = "companyname-"
# or a list
default_for = ["companyname-"]
I'm willing to spend time implementing this, btw.
@Kroppeb Have you tried this? We are using Azure Artifacts
to host private repos.
The below config is from our Pipfile
[[source]]
url = "https://{USER_NAME}:{PASSWORD}@pkgs.dev.azure.com/mYoRD/_packaging/lib-python%40Local/pypi/simple/"
verify_ssl = false
name = "home"
@sudharsan2020 Not sure what you mean? Are you suggesting to use our private repo als the only source?