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

Document how to add a list of values to the config file #7804

Closed
stonecharioteer opened this issue Feb 28, 2020 · 5 comments · Fixed by #7918
Closed

Document how to add a list of values to the config file #7804

stonecharioteer opened this issue Feb 28, 2020 · 5 comments · Fixed by #7918
Labels
auto-locked Outdated issues that have been locked by automation state: awaiting PR Feature discussed, PR is needed type: docs Documentation related

Comments

@stonecharioteer
Copy link

Related to #7803
(Splitting into 2 as suggested by @pradyunsg)

It would be helpful to document how to add a "list" of values to a section in the ini file. This helps generalize the problem defined in the aforementioned issue.

This helps readers learn how to add multiple links to find-links as already documented in the user guide, but also to apply this knowledge into other areas.

Perhaps it would fit as a "protip" sort of section for the config. For example:

It is possible to **append** values to a section within an ini file such as the pip.ini file.

.. code:: ini
    
    [install]
    find-links =
        http://mirror1.example.com
        http://mirror2.example.com

This enables users to add additional values in the order of entry.
@triage-new-issues triage-new-issues bot added the S: needs triage Issues/PRs that need to be triaged label Feb 28, 2020
@uranusjr
Copy link
Member

I’ll go ahead and label as awaiting PR :)

@uranusjr uranusjr added state: awaiting PR Feature discussed, PR is needed type: docs Documentation related and removed S: needs triage Issues/PRs that need to be triaged labels Feb 28, 2020
@deveshks
Copy link
Contributor

deveshks commented Mar 28, 2020

Hi @uranusjr ,

Can I take up this issue and create a PR for the same? I am thinking of adding a subsection right before https://github.com/pypa/pip/blob/master/docs/html/user_guide.rst#environment-variables like below. This can also resolve #7803

It is possible to **append** values to a section within an ini file such as the pip.ini file. 
This is applicable to appending options like --find-links or --trusted-hosts, 
which can be written on multiple lines:

.. code-block:: ini
    
[global]
find-links =
    http://download.example.com

[install]
find-links =
    http://mirror1.example.com
    http://mirror2.example.com

[install]
trusted-host = 
    https://pypi.org
    https://artifactory.mydomain.com

This enables users to add additional values in the order of entry for such command line args

@uranusjr
Copy link
Member

@deveshks Go ahead! Your examples look very nice to me 😄

@deveshks
Copy link
Contributor

Thanks @uranusjr . I have created the PR for the same. Please take a look

@xavfernandez
Copy link
Member

Closed by #7918

@lock lock bot added the auto-locked Outdated issues that have been locked by automation label May 5, 2020
@lock lock bot locked as resolved and limited conversation to collaborators May 5, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
auto-locked Outdated issues that have been locked by automation state: awaiting PR Feature discussed, PR is needed type: docs Documentation related
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants