PyPI protocol commands

Use the PyPI commands to work with PyPI artifacts in Helix Artifacts. You can use .pypirc or pip.conf files for your PyPI repository commands.

Downloading a package from a repository

Tip

You can specify more than one index and install location in to the file if required.

Example using a pip.conf file:

To download a package from a repository, edit your pip.conf file to contain the following:

[search]
index = http://localhost:1606/repo/samplePyPI
 
[install]
index-url = http://localhost:1606/repo/samplePyPI
username = <username>
password = <ticket>

Then use the following command:

python3 -m pip install active-alchemy --index-url=http://localhost:1606/repo/samplePyPI

Deploying a package to a custom index

Tip

You can specify more than one entry in the index-servers if required.

Example using a .pypirc file:

To deploy a package to a custom index, add the following to your .pypirc file:

[distutils]
index-servers =
    private-repository
 
[private-repository]
repository = http://localhost:1606/repo/samplePyPI
username = <username>
password = <ticket>

Then use the following command:

python3 -m twine upload --repository private-repository src/main/resources/p4python-2015.1.1005721-cp27-none-win32.whl

If you do not specify the username and password in the .pypirc file, you will be prompted for them. Make sure you use your <ticket> for the password.

If the command is successful, you will see a message similar to the one below:

Uploading distributions to http://localhost:1606/repo/samplePyPI