Skip to content
Snippets Groups Projects
Commit 047c3be0 authored by Spencer Williams's avatar Spencer Williams
Browse files

fix test doc build and document twine mixup

parent a724bade
No related branches found
No related tags found
No related merge requests found
......@@ -47,7 +47,7 @@ pygments_style = 'sphinx'
# -- Options for HTML output -------------------------------------------------
html_theme_path = ['_themes']
html_theme = 'sphinx_rigado_theme'
html_static_path = ['_static']
# html_static_path = ['_static']
html_sidebars = {
'**': ['searchbar.html',
'globaltoc.html',
......
......@@ -17,3 +17,59 @@ To publish:
1. make sure version is ok in ``sphinx_rigado_theme/__init__.py``
2. ``python3 setup.py sdist bdist_wheel``
3. ``twine upload dist/sphinx_rigado_theme-0.0.3*``
Don't have twine?
=================
I tried running the above to deploy a new version, and realized I didn't have twine. No matter:
.. code::
$ pip3 install twine
...
Could not install packages due to an EnvironmentError: [Errno 13] Permission denied: '/usr/local/bin/pygmentize'
Consider using the `--user` option or check the permissions.
$ pip install twine
...
Could not install packages due to an EnvironmentError: [Errno 13] Permission denied: '/usr/local/bin/pygmentize'
Consider using the `--user` option or check the permissions.
Huh. ok...
.. code::
$ pip3 install twine --user
...
Successfully installed bleach-3.1.0 readme-renderer-24.0 twine-1.13.0 webencodings-0.5.1
$ twine upload dist/sphinx_rigado_theme-0.0.13*
UploadToDeprecatedPyPIDetected: You're trying to upload to the legacy PyPI site 'https://pypi.python.org/pypi'. Uploading to those sites is deprecated.
The new sites are pypi.org and test.pypi.org. Try using https://upload.pypi.org/legacy/ (or https://test.pypi.org/legacy/) to upload your packages instead. These are the default URLs for Twine now.
More at https://packaging.python.org/guides/migrating-to-pypi-org/
This rings a bell. I need to configure twine now, I think. Yep, edit ``~/.pypirc``:
.. code::
[distutils]
index-servers =
pypi
pypitest
[pypi]
username=REDACTED
password=REDACTED
[pypitest]
username=REDACTED
password=REDACTED
.. note:: This file used to have some repository urls in it. These were old URLs (e.g. ``https://pypi.python.org/pypi`` listed above). I also tried updating them to new URLs (``https://pypi.org``), but got an HTTP error. Removing the URLs altogether seemed to work though:
.. code::
$ twine upload dist/sphinx_rigado_theme-0.0.13*
Uploading distributions to https://upload.pypi.org/legacy/
Uploading sphinx_rigado_theme-0.0.13-py3-none-any.whl
Uploading sphinx_rigado_theme-0.0.13.tar.gz
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment