2013-02-27 14:00:20 -04:00
|
|
|
.. index::
|
|
|
|
single: Python Package Index (PyPI)
|
|
|
|
single: PyPI; (see Python Package Index (PyPI))
|
|
|
|
|
2007-08-15 11:28:22 -03:00
|
|
|
.. _package-index:
|
|
|
|
|
2013-02-27 14:00:20 -04:00
|
|
|
*******************************
|
|
|
|
The Python Package Index (PyPI)
|
|
|
|
*******************************
|
|
|
|
|
2014-10-12 14:14:12 -03:00
|
|
|
The `Python Package Index (PyPI)`_ stores :ref:`meta-data <meta-data>`
|
2013-02-27 14:00:20 -04:00
|
|
|
describing distributions packaged with distutils, as well as package data like
|
2014-10-12 14:14:12 -03:00
|
|
|
distribution files if a package author wishes.
|
|
|
|
|
|
|
|
Distutils provides the :command:`register` and :command:`upload` commands for
|
|
|
|
pushing meta-data and distribution files to PyPI, respectively. See
|
|
|
|
:ref:`package-commands` for information on these commands.
|
|
|
|
|
|
|
|
|
|
|
|
PyPI overview
|
|
|
|
=============
|
|
|
|
|
|
|
|
PyPI lets you submit any number of versions of your distribution to the index.
|
|
|
|
If you alter the meta-data for a particular version, you can submit it again
|
|
|
|
and the index will be updated.
|
|
|
|
|
|
|
|
PyPI holds a record for each (name, version) combination submitted. The first
|
|
|
|
user to submit information for a given name is designated the Owner of that
|
|
|
|
name. Changes can be submitted through the :command:`register` command or
|
|
|
|
through the web interface. Owners can designate other users as Owners or
|
|
|
|
Maintainers. Maintainers can edit the package information, but not designate
|
|
|
|
new Owners or Maintainers.
|
|
|
|
|
|
|
|
By default PyPI displays only the newest version of a given package. The web
|
|
|
|
interface lets one change this default behavior and manually select which
|
|
|
|
versions to display and hide.
|
|
|
|
|
|
|
|
For each version, PyPI displays a home page. The home page is created from
|
|
|
|
the ``long_description`` which can be submitted via the :command:`register`
|
|
|
|
command. See :ref:`package-display` for more information.
|
|
|
|
|
|
|
|
|
|
|
|
.. _package-commands:
|
|
|
|
|
|
|
|
Distutils commands
|
|
|
|
==================
|
2013-02-27 14:00:20 -04:00
|
|
|
|
|
|
|
Distutils exposes two commands for submitting package data to PyPI: the
|
|
|
|
:ref:`register <package-register>` command for submitting meta-data to PyPI
|
|
|
|
and the :ref:`upload <package-upload>` command for submitting distribution
|
2014-10-12 14:14:12 -03:00
|
|
|
files. Both commands read configuration data from a special file called a
|
|
|
|
:ref:`.pypirc file <pypirc>`.
|
2013-02-27 14:00:20 -04:00
|
|
|
|
|
|
|
|
|
|
|
.. _package-register:
|
2007-08-15 11:28:22 -03:00
|
|
|
|
2014-10-12 14:14:12 -03:00
|
|
|
The ``register`` command
|
|
|
|
------------------------
|
2013-02-27 14:00:20 -04:00
|
|
|
|
|
|
|
The distutils command :command:`register` is used to submit your distribution's
|
2014-10-12 14:14:12 -03:00
|
|
|
meta-data to an index server. It is invoked as follows::
|
2007-08-15 11:28:22 -03:00
|
|
|
|
2009-01-08 20:15:45 -04:00
|
|
|
python setup.py register
|
2007-08-15 11:28:22 -03:00
|
|
|
|
|
|
|
Distutils will respond with the following prompt::
|
|
|
|
|
2009-01-08 20:15:45 -04:00
|
|
|
running register
|
|
|
|
We need to know who you are, so please choose either:
|
|
|
|
1. use your existing login,
|
|
|
|
2. register as a new user,
|
|
|
|
3. have the server generate a new password for you (and email it to you), or
|
|
|
|
4. quit
|
|
|
|
Your selection [default 1]:
|
2007-08-15 11:28:22 -03:00
|
|
|
|
|
|
|
Note: if your username and password are saved locally, you will not see this
|
2014-10-12 14:14:12 -03:00
|
|
|
menu. Also, refer to :ref:`pypirc` for how to store your credentials in a
|
|
|
|
:file:`.pypirc` file.
|
2007-08-15 11:28:22 -03:00
|
|
|
|
|
|
|
If you have not registered with PyPI, then you will need to do so now. You
|
|
|
|
should choose option 2, and enter your details as required. Soon after
|
|
|
|
submitting your details, you will receive an email which will be used to confirm
|
|
|
|
your registration.
|
|
|
|
|
|
|
|
Once you are registered, you may choose option 1 from the menu. You will be
|
|
|
|
prompted for your PyPI username and password, and :command:`register` will then
|
|
|
|
submit your meta-data to the index.
|
|
|
|
|
2014-10-12 14:14:12 -03:00
|
|
|
See :ref:`package-cmdoptions` for options to the :command:`register` command.
|
2007-08-15 11:28:22 -03:00
|
|
|
|
|
|
|
|
2013-02-27 14:00:20 -04:00
|
|
|
.. _package-upload:
|
|
|
|
|
2014-10-12 14:14:12 -03:00
|
|
|
The ``upload`` command
|
|
|
|
----------------------
|
2013-02-27 14:00:20 -04:00
|
|
|
|
|
|
|
The distutils command :command:`upload` pushes the distribution files to PyPI.
|
|
|
|
|
|
|
|
The command is invoked immediately after building one or more distribution
|
|
|
|
files. For example, the command ::
|
|
|
|
|
|
|
|
python setup.py sdist bdist_wininst upload
|
|
|
|
|
|
|
|
will cause the source distribution and the Windows installer to be uploaded to
|
|
|
|
PyPI. Note that these will be uploaded even if they are built using an earlier
|
|
|
|
invocation of :file:`setup.py`, but that only distributions named on the command
|
|
|
|
line for the invocation including the :command:`upload` command are uploaded.
|
|
|
|
|
2014-10-12 14:14:12 -03:00
|
|
|
If a :command:`register` command was previously called in the same command,
|
2013-02-27 14:00:20 -04:00
|
|
|
and if the password was entered in the prompt, :command:`upload` will reuse the
|
2014-10-12 14:14:12 -03:00
|
|
|
entered password. This is useful if you do not want to store a password in
|
|
|
|
clear text in a :file:`.pypirc` file.
|
2013-02-27 14:00:20 -04:00
|
|
|
|
|
|
|
You can use the ``--sign`` option to tell :command:`upload` to sign each
|
|
|
|
uploaded file using GPG (GNU Privacy Guard). The :program:`gpg` program must
|
|
|
|
be available for execution on the system :envvar:`PATH`. You can also specify
|
|
|
|
which key to use for signing using the ``--identity=name`` option.
|
|
|
|
|
2014-10-12 14:14:12 -03:00
|
|
|
See :ref:`package-cmdoptions` for additional options to the :command:`upload`
|
|
|
|
command.
|
|
|
|
|
|
|
|
|
|
|
|
.. _package-cmdoptions:
|
|
|
|
|
|
|
|
Additional command options
|
|
|
|
--------------------------
|
|
|
|
|
|
|
|
This section describes options common to both the :command:`register` and
|
|
|
|
:command:`upload` commands.
|
|
|
|
|
|
|
|
The ``--repository`` or ``-r`` option lets you specify a PyPI server
|
|
|
|
different from the default. For example::
|
|
|
|
|
|
|
|
python setup.py sdist bdist_wininst upload -r https://example.com/pypi
|
|
|
|
|
|
|
|
For convenience, a name can be used in place of the URL when the
|
|
|
|
:file:`.pypirc` file is configured to do so. For example::
|
|
|
|
|
|
|
|
python setup.py register -r other
|
|
|
|
|
|
|
|
See :ref:`pypirc` for more information on defining alternate servers.
|
|
|
|
|
|
|
|
The ``--show-response`` option displays the full response text from the PyPI
|
|
|
|
server, which is useful when debugging problems with registering and uploading.
|
2013-02-27 14:00:20 -04:00
|
|
|
|
|
|
|
|
|
|
|
.. index::
|
|
|
|
single: .pypirc file
|
|
|
|
single: Python Package Index (PyPI); .pypirc file
|
|
|
|
|
2007-08-15 11:28:22 -03:00
|
|
|
.. _pypirc:
|
|
|
|
|
2014-10-12 14:14:12 -03:00
|
|
|
The ``.pypirc`` file
|
|
|
|
--------------------
|
2007-08-15 11:28:22 -03:00
|
|
|
|
2014-10-12 14:14:12 -03:00
|
|
|
The :command:`register` and :command:`upload` commands both check for the
|
|
|
|
existence of a :file:`.pypirc` file at the location :file:`$HOME/.pypirc`.
|
|
|
|
If this file exists, the command uses the username, password, and repository
|
|
|
|
URL configured in the file. The format of a :file:`.pypirc` file is as
|
|
|
|
follows::
|
2007-08-15 11:28:22 -03:00
|
|
|
|
2009-01-08 20:15:45 -04:00
|
|
|
[distutils]
|
|
|
|
index-servers =
|
|
|
|
pypi
|
Merged revisions 62998-63003,63005-63006,63009-63012,63014-63017,63019-63020,63022-63024,63026-63029,63031-63041,63043-63045,63047-63054,63056-63062 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk
........
r62998 | andrew.kuchling | 2008-05-10 15:51:55 -0400 (Sat, 10 May 2008) | 7 lines
#1858 from Tarek Ziade:
Allow multiple repositories in .pypirc; see http://wiki.python.org/moin/EnhancedPyPI
for discussion.
The patch is slightly revised from Tarek's last patch: I've simplified
the PyPIRCCommand.finalize_options() method to not look at sys.argv.
Tests still pass.
........
r63000 | alexandre.vassalotti | 2008-05-10 15:59:16 -0400 (Sat, 10 May 2008) | 5 lines
Cleaned up io._BytesIO.write().
I am amazed that the old code, for inserting null-bytes, actually
worked. Who wrote that thing? Oh, it is me... doh.
........
r63002 | brett.cannon | 2008-05-10 16:52:01 -0400 (Sat, 10 May 2008) | 2 lines
Revert r62998 as it broke the build (seems distutils.config is missing).
........
r63014 | andrew.kuchling | 2008-05-10 18:12:38 -0400 (Sat, 10 May 2008) | 1 line
#1858: add distutils.config module
........
r63027 | brett.cannon | 2008-05-10 21:09:32 -0400 (Sat, 10 May 2008) | 2 lines
Flesh out the 3.0 deprecation to suggest using the ctypes module.
........
r63028 | skip.montanaro | 2008-05-10 22:59:30 -0400 (Sat, 10 May 2008) | 4 lines
Copied two versions of the example from the interactive session. Delete
one.
........
r63037 | georg.brandl | 2008-05-11 03:02:17 -0400 (Sun, 11 May 2008) | 2 lines
reload() takes the module itself.
........
r63038 | alexandre.vassalotti | 2008-05-11 03:06:04 -0400 (Sun, 11 May 2008) | 4 lines
Added test framework for handling module renames.
Factored the import guard in test_py3kwarn.TestStdlibRemovals into
a context manager, namely test_support.CleanImport.
........
r63039 | georg.brandl | 2008-05-11 03:06:05 -0400 (Sun, 11 May 2008) | 2 lines
#2742: ``''`` is not converted to NULL in getaddrinfo.
........
r63040 | alexandre.vassalotti | 2008-05-11 03:08:12 -0400 (Sun, 11 May 2008) | 2 lines
Fixed typo in a comment of test_support.CleanImport.
........
r63041 | alexandre.vassalotti | 2008-05-11 03:10:25 -0400 (Sun, 11 May 2008) | 2 lines
Removed a dead line of code.
........
r63043 | georg.brandl | 2008-05-11 04:47:53 -0400 (Sun, 11 May 2008) | 2 lines
#2812: document property.getter/setter/deleter.
........
r63049 | georg.brandl | 2008-05-11 05:06:30 -0400 (Sun, 11 May 2008) | 2 lines
#1153769: document PEP 237 changes to string formatting.
........
r63050 | georg.brandl | 2008-05-11 05:11:40 -0400 (Sun, 11 May 2008) | 2 lines
#2809: elaborate str.split docstring a bit.
........
r63051 | georg.brandl | 2008-05-11 06:13:59 -0400 (Sun, 11 May 2008) | 2 lines
Fix typo.
........
r63052 | georg.brandl | 2008-05-11 06:33:27 -0400 (Sun, 11 May 2008) | 2 lines
#2709: clarification.
........
r63053 | georg.brandl | 2008-05-11 06:42:28 -0400 (Sun, 11 May 2008) | 2 lines
#2659: add ``break_on_hyphens`` to TextWrapper.
........
r63057 | georg.brandl | 2008-05-11 06:59:39 -0400 (Sun, 11 May 2008) | 2 lines
#2741: clarification of value range for address_family.
........
r63058 | georg.brandl | 2008-05-11 07:09:35 -0400 (Sun, 11 May 2008) | 2 lines
#2452: timeout is used for all blocking operations.
........
r63059 | andrew.kuchling | 2008-05-11 09:33:56 -0400 (Sun, 11 May 2008) | 2 lines
#1792: Improve performance of marshal.dumps() on large objects by increasing
the size of the buffer more quickly.
........
r63060 | andrew.kuchling | 2008-05-11 10:00:00 -0400 (Sun, 11 May 2008) | 1 line
#1858: re-apply patch for this, adding the missing files
........
r63061 | benjamin.peterson | 2008-05-11 10:13:25 -0400 (Sun, 11 May 2008) | 2 lines
Add the "until" command to pdb
........
r63062 | georg.brandl | 2008-05-11 10:17:13 -0400 (Sun, 11 May 2008) | 2 lines
Add some sentence endings.
........
2008-05-15 21:03:33 -03:00
|
|
|
|
2009-01-08 20:15:45 -04:00
|
|
|
[pypi]
|
|
|
|
repository: <repository-url>
|
|
|
|
username: <username>
|
|
|
|
password: <password>
|
2007-08-15 11:28:22 -03:00
|
|
|
|
2015-11-02 08:10:23 -04:00
|
|
|
The *distutils* section defines an *index-servers* variable that lists the
|
2009-01-08 20:15:45 -04:00
|
|
|
name of all sections describing a repository.
|
2007-08-15 11:28:22 -03:00
|
|
|
|
2009-01-08 20:15:45 -04:00
|
|
|
Each section describing a repository defines three variables:
|
Merged revisions 62998-63003,63005-63006,63009-63012,63014-63017,63019-63020,63022-63024,63026-63029,63031-63041,63043-63045,63047-63054,63056-63062 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk
........
r62998 | andrew.kuchling | 2008-05-10 15:51:55 -0400 (Sat, 10 May 2008) | 7 lines
#1858 from Tarek Ziade:
Allow multiple repositories in .pypirc; see http://wiki.python.org/moin/EnhancedPyPI
for discussion.
The patch is slightly revised from Tarek's last patch: I've simplified
the PyPIRCCommand.finalize_options() method to not look at sys.argv.
Tests still pass.
........
r63000 | alexandre.vassalotti | 2008-05-10 15:59:16 -0400 (Sat, 10 May 2008) | 5 lines
Cleaned up io._BytesIO.write().
I am amazed that the old code, for inserting null-bytes, actually
worked. Who wrote that thing? Oh, it is me... doh.
........
r63002 | brett.cannon | 2008-05-10 16:52:01 -0400 (Sat, 10 May 2008) | 2 lines
Revert r62998 as it broke the build (seems distutils.config is missing).
........
r63014 | andrew.kuchling | 2008-05-10 18:12:38 -0400 (Sat, 10 May 2008) | 1 line
#1858: add distutils.config module
........
r63027 | brett.cannon | 2008-05-10 21:09:32 -0400 (Sat, 10 May 2008) | 2 lines
Flesh out the 3.0 deprecation to suggest using the ctypes module.
........
r63028 | skip.montanaro | 2008-05-10 22:59:30 -0400 (Sat, 10 May 2008) | 4 lines
Copied two versions of the example from the interactive session. Delete
one.
........
r63037 | georg.brandl | 2008-05-11 03:02:17 -0400 (Sun, 11 May 2008) | 2 lines
reload() takes the module itself.
........
r63038 | alexandre.vassalotti | 2008-05-11 03:06:04 -0400 (Sun, 11 May 2008) | 4 lines
Added test framework for handling module renames.
Factored the import guard in test_py3kwarn.TestStdlibRemovals into
a context manager, namely test_support.CleanImport.
........
r63039 | georg.brandl | 2008-05-11 03:06:05 -0400 (Sun, 11 May 2008) | 2 lines
#2742: ``''`` is not converted to NULL in getaddrinfo.
........
r63040 | alexandre.vassalotti | 2008-05-11 03:08:12 -0400 (Sun, 11 May 2008) | 2 lines
Fixed typo in a comment of test_support.CleanImport.
........
r63041 | alexandre.vassalotti | 2008-05-11 03:10:25 -0400 (Sun, 11 May 2008) | 2 lines
Removed a dead line of code.
........
r63043 | georg.brandl | 2008-05-11 04:47:53 -0400 (Sun, 11 May 2008) | 2 lines
#2812: document property.getter/setter/deleter.
........
r63049 | georg.brandl | 2008-05-11 05:06:30 -0400 (Sun, 11 May 2008) | 2 lines
#1153769: document PEP 237 changes to string formatting.
........
r63050 | georg.brandl | 2008-05-11 05:11:40 -0400 (Sun, 11 May 2008) | 2 lines
#2809: elaborate str.split docstring a bit.
........
r63051 | georg.brandl | 2008-05-11 06:13:59 -0400 (Sun, 11 May 2008) | 2 lines
Fix typo.
........
r63052 | georg.brandl | 2008-05-11 06:33:27 -0400 (Sun, 11 May 2008) | 2 lines
#2709: clarification.
........
r63053 | georg.brandl | 2008-05-11 06:42:28 -0400 (Sun, 11 May 2008) | 2 lines
#2659: add ``break_on_hyphens`` to TextWrapper.
........
r63057 | georg.brandl | 2008-05-11 06:59:39 -0400 (Sun, 11 May 2008) | 2 lines
#2741: clarification of value range for address_family.
........
r63058 | georg.brandl | 2008-05-11 07:09:35 -0400 (Sun, 11 May 2008) | 2 lines
#2452: timeout is used for all blocking operations.
........
r63059 | andrew.kuchling | 2008-05-11 09:33:56 -0400 (Sun, 11 May 2008) | 2 lines
#1792: Improve performance of marshal.dumps() on large objects by increasing
the size of the buffer more quickly.
........
r63060 | andrew.kuchling | 2008-05-11 10:00:00 -0400 (Sun, 11 May 2008) | 1 line
#1858: re-apply patch for this, adding the missing files
........
r63061 | benjamin.peterson | 2008-05-11 10:13:25 -0400 (Sun, 11 May 2008) | 2 lines
Add the "until" command to pdb
........
r63062 | georg.brandl | 2008-05-11 10:17:13 -0400 (Sun, 11 May 2008) | 2 lines
Add some sentence endings.
........
2008-05-15 21:03:33 -03:00
|
|
|
|
2009-01-08 20:15:45 -04:00
|
|
|
- *repository*, that defines the url of the PyPI server. Defaults to
|
2014-10-12 14:14:12 -03:00
|
|
|
``https://www.python.org/pypi``.
|
2009-01-08 20:15:45 -04:00
|
|
|
- *username*, which is the registered username on the PyPI server.
|
|
|
|
- *password*, that will be used to authenticate. If omitted the user
|
|
|
|
will be prompt to type it when needed.
|
2009-01-03 17:18:54 -04:00
|
|
|
|
2009-01-08 20:15:45 -04:00
|
|
|
If you want to define another server a new section can be created and
|
|
|
|
listed in the *index-servers* variable::
|
Merged revisions 62998-63003,63005-63006,63009-63012,63014-63017,63019-63020,63022-63024,63026-63029,63031-63041,63043-63045,63047-63054,63056-63062 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk
........
r62998 | andrew.kuchling | 2008-05-10 15:51:55 -0400 (Sat, 10 May 2008) | 7 lines
#1858 from Tarek Ziade:
Allow multiple repositories in .pypirc; see http://wiki.python.org/moin/EnhancedPyPI
for discussion.
The patch is slightly revised from Tarek's last patch: I've simplified
the PyPIRCCommand.finalize_options() method to not look at sys.argv.
Tests still pass.
........
r63000 | alexandre.vassalotti | 2008-05-10 15:59:16 -0400 (Sat, 10 May 2008) | 5 lines
Cleaned up io._BytesIO.write().
I am amazed that the old code, for inserting null-bytes, actually
worked. Who wrote that thing? Oh, it is me... doh.
........
r63002 | brett.cannon | 2008-05-10 16:52:01 -0400 (Sat, 10 May 2008) | 2 lines
Revert r62998 as it broke the build (seems distutils.config is missing).
........
r63014 | andrew.kuchling | 2008-05-10 18:12:38 -0400 (Sat, 10 May 2008) | 1 line
#1858: add distutils.config module
........
r63027 | brett.cannon | 2008-05-10 21:09:32 -0400 (Sat, 10 May 2008) | 2 lines
Flesh out the 3.0 deprecation to suggest using the ctypes module.
........
r63028 | skip.montanaro | 2008-05-10 22:59:30 -0400 (Sat, 10 May 2008) | 4 lines
Copied two versions of the example from the interactive session. Delete
one.
........
r63037 | georg.brandl | 2008-05-11 03:02:17 -0400 (Sun, 11 May 2008) | 2 lines
reload() takes the module itself.
........
r63038 | alexandre.vassalotti | 2008-05-11 03:06:04 -0400 (Sun, 11 May 2008) | 4 lines
Added test framework for handling module renames.
Factored the import guard in test_py3kwarn.TestStdlibRemovals into
a context manager, namely test_support.CleanImport.
........
r63039 | georg.brandl | 2008-05-11 03:06:05 -0400 (Sun, 11 May 2008) | 2 lines
#2742: ``''`` is not converted to NULL in getaddrinfo.
........
r63040 | alexandre.vassalotti | 2008-05-11 03:08:12 -0400 (Sun, 11 May 2008) | 2 lines
Fixed typo in a comment of test_support.CleanImport.
........
r63041 | alexandre.vassalotti | 2008-05-11 03:10:25 -0400 (Sun, 11 May 2008) | 2 lines
Removed a dead line of code.
........
r63043 | georg.brandl | 2008-05-11 04:47:53 -0400 (Sun, 11 May 2008) | 2 lines
#2812: document property.getter/setter/deleter.
........
r63049 | georg.brandl | 2008-05-11 05:06:30 -0400 (Sun, 11 May 2008) | 2 lines
#1153769: document PEP 237 changes to string formatting.
........
r63050 | georg.brandl | 2008-05-11 05:11:40 -0400 (Sun, 11 May 2008) | 2 lines
#2809: elaborate str.split docstring a bit.
........
r63051 | georg.brandl | 2008-05-11 06:13:59 -0400 (Sun, 11 May 2008) | 2 lines
Fix typo.
........
r63052 | georg.brandl | 2008-05-11 06:33:27 -0400 (Sun, 11 May 2008) | 2 lines
#2709: clarification.
........
r63053 | georg.brandl | 2008-05-11 06:42:28 -0400 (Sun, 11 May 2008) | 2 lines
#2659: add ``break_on_hyphens`` to TextWrapper.
........
r63057 | georg.brandl | 2008-05-11 06:59:39 -0400 (Sun, 11 May 2008) | 2 lines
#2741: clarification of value range for address_family.
........
r63058 | georg.brandl | 2008-05-11 07:09:35 -0400 (Sun, 11 May 2008) | 2 lines
#2452: timeout is used for all blocking operations.
........
r63059 | andrew.kuchling | 2008-05-11 09:33:56 -0400 (Sun, 11 May 2008) | 2 lines
#1792: Improve performance of marshal.dumps() on large objects by increasing
the size of the buffer more quickly.
........
r63060 | andrew.kuchling | 2008-05-11 10:00:00 -0400 (Sun, 11 May 2008) | 1 line
#1858: re-apply patch for this, adding the missing files
........
r63061 | benjamin.peterson | 2008-05-11 10:13:25 -0400 (Sun, 11 May 2008) | 2 lines
Add the "until" command to pdb
........
r63062 | georg.brandl | 2008-05-11 10:17:13 -0400 (Sun, 11 May 2008) | 2 lines
Add some sentence endings.
........
2008-05-15 21:03:33 -03:00
|
|
|
|
2009-01-08 20:15:45 -04:00
|
|
|
[distutils]
|
|
|
|
index-servers =
|
|
|
|
pypi
|
|
|
|
other
|
Merged revisions 62998-63003,63005-63006,63009-63012,63014-63017,63019-63020,63022-63024,63026-63029,63031-63041,63043-63045,63047-63054,63056-63062 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk
........
r62998 | andrew.kuchling | 2008-05-10 15:51:55 -0400 (Sat, 10 May 2008) | 7 lines
#1858 from Tarek Ziade:
Allow multiple repositories in .pypirc; see http://wiki.python.org/moin/EnhancedPyPI
for discussion.
The patch is slightly revised from Tarek's last patch: I've simplified
the PyPIRCCommand.finalize_options() method to not look at sys.argv.
Tests still pass.
........
r63000 | alexandre.vassalotti | 2008-05-10 15:59:16 -0400 (Sat, 10 May 2008) | 5 lines
Cleaned up io._BytesIO.write().
I am amazed that the old code, for inserting null-bytes, actually
worked. Who wrote that thing? Oh, it is me... doh.
........
r63002 | brett.cannon | 2008-05-10 16:52:01 -0400 (Sat, 10 May 2008) | 2 lines
Revert r62998 as it broke the build (seems distutils.config is missing).
........
r63014 | andrew.kuchling | 2008-05-10 18:12:38 -0400 (Sat, 10 May 2008) | 1 line
#1858: add distutils.config module
........
r63027 | brett.cannon | 2008-05-10 21:09:32 -0400 (Sat, 10 May 2008) | 2 lines
Flesh out the 3.0 deprecation to suggest using the ctypes module.
........
r63028 | skip.montanaro | 2008-05-10 22:59:30 -0400 (Sat, 10 May 2008) | 4 lines
Copied two versions of the example from the interactive session. Delete
one.
........
r63037 | georg.brandl | 2008-05-11 03:02:17 -0400 (Sun, 11 May 2008) | 2 lines
reload() takes the module itself.
........
r63038 | alexandre.vassalotti | 2008-05-11 03:06:04 -0400 (Sun, 11 May 2008) | 4 lines
Added test framework for handling module renames.
Factored the import guard in test_py3kwarn.TestStdlibRemovals into
a context manager, namely test_support.CleanImport.
........
r63039 | georg.brandl | 2008-05-11 03:06:05 -0400 (Sun, 11 May 2008) | 2 lines
#2742: ``''`` is not converted to NULL in getaddrinfo.
........
r63040 | alexandre.vassalotti | 2008-05-11 03:08:12 -0400 (Sun, 11 May 2008) | 2 lines
Fixed typo in a comment of test_support.CleanImport.
........
r63041 | alexandre.vassalotti | 2008-05-11 03:10:25 -0400 (Sun, 11 May 2008) | 2 lines
Removed a dead line of code.
........
r63043 | georg.brandl | 2008-05-11 04:47:53 -0400 (Sun, 11 May 2008) | 2 lines
#2812: document property.getter/setter/deleter.
........
r63049 | georg.brandl | 2008-05-11 05:06:30 -0400 (Sun, 11 May 2008) | 2 lines
#1153769: document PEP 237 changes to string formatting.
........
r63050 | georg.brandl | 2008-05-11 05:11:40 -0400 (Sun, 11 May 2008) | 2 lines
#2809: elaborate str.split docstring a bit.
........
r63051 | georg.brandl | 2008-05-11 06:13:59 -0400 (Sun, 11 May 2008) | 2 lines
Fix typo.
........
r63052 | georg.brandl | 2008-05-11 06:33:27 -0400 (Sun, 11 May 2008) | 2 lines
#2709: clarification.
........
r63053 | georg.brandl | 2008-05-11 06:42:28 -0400 (Sun, 11 May 2008) | 2 lines
#2659: add ``break_on_hyphens`` to TextWrapper.
........
r63057 | georg.brandl | 2008-05-11 06:59:39 -0400 (Sun, 11 May 2008) | 2 lines
#2741: clarification of value range for address_family.
........
r63058 | georg.brandl | 2008-05-11 07:09:35 -0400 (Sun, 11 May 2008) | 2 lines
#2452: timeout is used for all blocking operations.
........
r63059 | andrew.kuchling | 2008-05-11 09:33:56 -0400 (Sun, 11 May 2008) | 2 lines
#1792: Improve performance of marshal.dumps() on large objects by increasing
the size of the buffer more quickly.
........
r63060 | andrew.kuchling | 2008-05-11 10:00:00 -0400 (Sun, 11 May 2008) | 1 line
#1858: re-apply patch for this, adding the missing files
........
r63061 | benjamin.peterson | 2008-05-11 10:13:25 -0400 (Sun, 11 May 2008) | 2 lines
Add the "until" command to pdb
........
r63062 | georg.brandl | 2008-05-11 10:17:13 -0400 (Sun, 11 May 2008) | 2 lines
Add some sentence endings.
........
2008-05-15 21:03:33 -03:00
|
|
|
|
2009-01-08 20:15:45 -04:00
|
|
|
[pypi]
|
|
|
|
repository: <repository-url>
|
|
|
|
username: <username>
|
|
|
|
password: <password>
|
Merged revisions 62998-63003,63005-63006,63009-63012,63014-63017,63019-63020,63022-63024,63026-63029,63031-63041,63043-63045,63047-63054,63056-63062 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk
........
r62998 | andrew.kuchling | 2008-05-10 15:51:55 -0400 (Sat, 10 May 2008) | 7 lines
#1858 from Tarek Ziade:
Allow multiple repositories in .pypirc; see http://wiki.python.org/moin/EnhancedPyPI
for discussion.
The patch is slightly revised from Tarek's last patch: I've simplified
the PyPIRCCommand.finalize_options() method to not look at sys.argv.
Tests still pass.
........
r63000 | alexandre.vassalotti | 2008-05-10 15:59:16 -0400 (Sat, 10 May 2008) | 5 lines
Cleaned up io._BytesIO.write().
I am amazed that the old code, for inserting null-bytes, actually
worked. Who wrote that thing? Oh, it is me... doh.
........
r63002 | brett.cannon | 2008-05-10 16:52:01 -0400 (Sat, 10 May 2008) | 2 lines
Revert r62998 as it broke the build (seems distutils.config is missing).
........
r63014 | andrew.kuchling | 2008-05-10 18:12:38 -0400 (Sat, 10 May 2008) | 1 line
#1858: add distutils.config module
........
r63027 | brett.cannon | 2008-05-10 21:09:32 -0400 (Sat, 10 May 2008) | 2 lines
Flesh out the 3.0 deprecation to suggest using the ctypes module.
........
r63028 | skip.montanaro | 2008-05-10 22:59:30 -0400 (Sat, 10 May 2008) | 4 lines
Copied two versions of the example from the interactive session. Delete
one.
........
r63037 | georg.brandl | 2008-05-11 03:02:17 -0400 (Sun, 11 May 2008) | 2 lines
reload() takes the module itself.
........
r63038 | alexandre.vassalotti | 2008-05-11 03:06:04 -0400 (Sun, 11 May 2008) | 4 lines
Added test framework for handling module renames.
Factored the import guard in test_py3kwarn.TestStdlibRemovals into
a context manager, namely test_support.CleanImport.
........
r63039 | georg.brandl | 2008-05-11 03:06:05 -0400 (Sun, 11 May 2008) | 2 lines
#2742: ``''`` is not converted to NULL in getaddrinfo.
........
r63040 | alexandre.vassalotti | 2008-05-11 03:08:12 -0400 (Sun, 11 May 2008) | 2 lines
Fixed typo in a comment of test_support.CleanImport.
........
r63041 | alexandre.vassalotti | 2008-05-11 03:10:25 -0400 (Sun, 11 May 2008) | 2 lines
Removed a dead line of code.
........
r63043 | georg.brandl | 2008-05-11 04:47:53 -0400 (Sun, 11 May 2008) | 2 lines
#2812: document property.getter/setter/deleter.
........
r63049 | georg.brandl | 2008-05-11 05:06:30 -0400 (Sun, 11 May 2008) | 2 lines
#1153769: document PEP 237 changes to string formatting.
........
r63050 | georg.brandl | 2008-05-11 05:11:40 -0400 (Sun, 11 May 2008) | 2 lines
#2809: elaborate str.split docstring a bit.
........
r63051 | georg.brandl | 2008-05-11 06:13:59 -0400 (Sun, 11 May 2008) | 2 lines
Fix typo.
........
r63052 | georg.brandl | 2008-05-11 06:33:27 -0400 (Sun, 11 May 2008) | 2 lines
#2709: clarification.
........
r63053 | georg.brandl | 2008-05-11 06:42:28 -0400 (Sun, 11 May 2008) | 2 lines
#2659: add ``break_on_hyphens`` to TextWrapper.
........
r63057 | georg.brandl | 2008-05-11 06:59:39 -0400 (Sun, 11 May 2008) | 2 lines
#2741: clarification of value range for address_family.
........
r63058 | georg.brandl | 2008-05-11 07:09:35 -0400 (Sun, 11 May 2008) | 2 lines
#2452: timeout is used for all blocking operations.
........
r63059 | andrew.kuchling | 2008-05-11 09:33:56 -0400 (Sun, 11 May 2008) | 2 lines
#1792: Improve performance of marshal.dumps() on large objects by increasing
the size of the buffer more quickly.
........
r63060 | andrew.kuchling | 2008-05-11 10:00:00 -0400 (Sun, 11 May 2008) | 1 line
#1858: re-apply patch for this, adding the missing files
........
r63061 | benjamin.peterson | 2008-05-11 10:13:25 -0400 (Sun, 11 May 2008) | 2 lines
Add the "until" command to pdb
........
r63062 | georg.brandl | 2008-05-11 10:17:13 -0400 (Sun, 11 May 2008) | 2 lines
Add some sentence endings.
........
2008-05-15 21:03:33 -03:00
|
|
|
|
2009-01-08 20:15:45 -04:00
|
|
|
[other]
|
2014-10-12 14:14:12 -03:00
|
|
|
repository: https://example.com/pypi
|
2009-01-08 20:15:45 -04:00
|
|
|
username: <username>
|
|
|
|
password: <password>
|
Merged revisions 62998-63003,63005-63006,63009-63012,63014-63017,63019-63020,63022-63024,63026-63029,63031-63041,63043-63045,63047-63054,63056-63062 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk
........
r62998 | andrew.kuchling | 2008-05-10 15:51:55 -0400 (Sat, 10 May 2008) | 7 lines
#1858 from Tarek Ziade:
Allow multiple repositories in .pypirc; see http://wiki.python.org/moin/EnhancedPyPI
for discussion.
The patch is slightly revised from Tarek's last patch: I've simplified
the PyPIRCCommand.finalize_options() method to not look at sys.argv.
Tests still pass.
........
r63000 | alexandre.vassalotti | 2008-05-10 15:59:16 -0400 (Sat, 10 May 2008) | 5 lines
Cleaned up io._BytesIO.write().
I am amazed that the old code, for inserting null-bytes, actually
worked. Who wrote that thing? Oh, it is me... doh.
........
r63002 | brett.cannon | 2008-05-10 16:52:01 -0400 (Sat, 10 May 2008) | 2 lines
Revert r62998 as it broke the build (seems distutils.config is missing).
........
r63014 | andrew.kuchling | 2008-05-10 18:12:38 -0400 (Sat, 10 May 2008) | 1 line
#1858: add distutils.config module
........
r63027 | brett.cannon | 2008-05-10 21:09:32 -0400 (Sat, 10 May 2008) | 2 lines
Flesh out the 3.0 deprecation to suggest using the ctypes module.
........
r63028 | skip.montanaro | 2008-05-10 22:59:30 -0400 (Sat, 10 May 2008) | 4 lines
Copied two versions of the example from the interactive session. Delete
one.
........
r63037 | georg.brandl | 2008-05-11 03:02:17 -0400 (Sun, 11 May 2008) | 2 lines
reload() takes the module itself.
........
r63038 | alexandre.vassalotti | 2008-05-11 03:06:04 -0400 (Sun, 11 May 2008) | 4 lines
Added test framework for handling module renames.
Factored the import guard in test_py3kwarn.TestStdlibRemovals into
a context manager, namely test_support.CleanImport.
........
r63039 | georg.brandl | 2008-05-11 03:06:05 -0400 (Sun, 11 May 2008) | 2 lines
#2742: ``''`` is not converted to NULL in getaddrinfo.
........
r63040 | alexandre.vassalotti | 2008-05-11 03:08:12 -0400 (Sun, 11 May 2008) | 2 lines
Fixed typo in a comment of test_support.CleanImport.
........
r63041 | alexandre.vassalotti | 2008-05-11 03:10:25 -0400 (Sun, 11 May 2008) | 2 lines
Removed a dead line of code.
........
r63043 | georg.brandl | 2008-05-11 04:47:53 -0400 (Sun, 11 May 2008) | 2 lines
#2812: document property.getter/setter/deleter.
........
r63049 | georg.brandl | 2008-05-11 05:06:30 -0400 (Sun, 11 May 2008) | 2 lines
#1153769: document PEP 237 changes to string formatting.
........
r63050 | georg.brandl | 2008-05-11 05:11:40 -0400 (Sun, 11 May 2008) | 2 lines
#2809: elaborate str.split docstring a bit.
........
r63051 | georg.brandl | 2008-05-11 06:13:59 -0400 (Sun, 11 May 2008) | 2 lines
Fix typo.
........
r63052 | georg.brandl | 2008-05-11 06:33:27 -0400 (Sun, 11 May 2008) | 2 lines
#2709: clarification.
........
r63053 | georg.brandl | 2008-05-11 06:42:28 -0400 (Sun, 11 May 2008) | 2 lines
#2659: add ``break_on_hyphens`` to TextWrapper.
........
r63057 | georg.brandl | 2008-05-11 06:59:39 -0400 (Sun, 11 May 2008) | 2 lines
#2741: clarification of value range for address_family.
........
r63058 | georg.brandl | 2008-05-11 07:09:35 -0400 (Sun, 11 May 2008) | 2 lines
#2452: timeout is used for all blocking operations.
........
r63059 | andrew.kuchling | 2008-05-11 09:33:56 -0400 (Sun, 11 May 2008) | 2 lines
#1792: Improve performance of marshal.dumps() on large objects by increasing
the size of the buffer more quickly.
........
r63060 | andrew.kuchling | 2008-05-11 10:00:00 -0400 (Sun, 11 May 2008) | 1 line
#1858: re-apply patch for this, adding the missing files
........
r63061 | benjamin.peterson | 2008-05-11 10:13:25 -0400 (Sun, 11 May 2008) | 2 lines
Add the "until" command to pdb
........
r63062 | georg.brandl | 2008-05-11 10:17:13 -0400 (Sun, 11 May 2008) | 2 lines
Add some sentence endings.
........
2008-05-15 21:03:33 -03:00
|
|
|
|
2014-10-12 14:14:12 -03:00
|
|
|
This allows the :command:`register` and :command:`upload` commands to be
|
|
|
|
called with the ``--repository`` option as described in
|
|
|
|
:ref:`package-cmdoptions`.
|
2007-08-15 11:28:22 -03:00
|
|
|
|
2014-10-12 14:14:12 -03:00
|
|
|
Specifically, you might want to add the `PyPI Test Repository
|
|
|
|
<https://wiki.python.org/moin/TestPyPI>`_ to your ``.pypirc`` to facilitate
|
|
|
|
testing before doing your first upload to ``PyPI`` itself.
|
2013-02-27 14:00:20 -04:00
|
|
|
|
|
|
|
|
|
|
|
.. _package-display:
|
|
|
|
|
|
|
|
PyPI package display
|
|
|
|
====================
|
|
|
|
|
|
|
|
The ``long_description`` field plays a special role at PyPI. It is used by
|
|
|
|
the server to display a home page for the registered package.
|
|
|
|
|
|
|
|
If you use the `reStructuredText <http://docutils.sourceforge.net/rst.html>`_
|
|
|
|
syntax for this field, PyPI will parse it and display an HTML output for
|
|
|
|
the package home page.
|
|
|
|
|
|
|
|
The ``long_description`` field can be attached to a text file located
|
|
|
|
in the package::
|
|
|
|
|
|
|
|
from distutils.core import setup
|
|
|
|
|
|
|
|
with open('README.txt') as file:
|
|
|
|
long_description = file.read()
|
|
|
|
|
|
|
|
setup(name='Distutils',
|
|
|
|
long_description=long_description)
|
|
|
|
|
|
|
|
In that case, :file:`README.txt` is a regular reStructuredText text file located
|
|
|
|
in the root of the package besides :file:`setup.py`.
|
|
|
|
|
|
|
|
To prevent registering broken reStructuredText content, you can use the
|
|
|
|
:program:`rst2html` program that is provided by the :mod:`docutils` package and
|
2016-07-26 06:18:21 -03:00
|
|
|
check the ``long_description`` from the command line:
|
|
|
|
|
|
|
|
.. code-block:: shell-session
|
2013-02-27 14:00:20 -04:00
|
|
|
|
|
|
|
$ python setup.py --long-description | rst2html.py > output.html
|
|
|
|
|
|
|
|
:mod:`docutils` will display a warning if there's something wrong with your
|
|
|
|
syntax. Because PyPI applies additional checks (e.g. by passing ``--no-raw``
|
|
|
|
to ``rst2html.py`` in the command above), being able to run the command above
|
|
|
|
without warnings does not guarantee that PyPI will convert the content
|
|
|
|
successfully.
|
|
|
|
|
|
|
|
|
2014-10-29 05:24:54 -03:00
|
|
|
.. _Python Package Index (PyPI): https://pypi.python.org/pypi
|