Skip to content

Commit

Permalink
Merge pull request #1345 from willingc/remove-doc-tutorial
Browse files Browse the repository at this point in the history
Remove the Creating Documentation tutorial
  • Loading branch information
pradyunsg committed Nov 5, 2023
2 parents 7f11a7e + 4c6680f commit 870a1bc
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 64 deletions.
67 changes: 4 additions & 63 deletions source/tutorials/creating-documentation.rst
Original file line number Diff line number Diff line change
@@ -1,66 +1,7 @@
.. _creating-documentation:
:orphan:

Creating documentation
======================
Creating Documentation
======================

This section covers the basics of how to create documentation using `Sphinx`_ and
host the documentation for free in `Read The Docs`_.

.. _Sphinx: https://www.sphinx-doc.org
.. _Read The Docs: https://readthedocs.org/

Installing Sphinx
-----------------
Use ``pip`` to install Sphinx:

.. tab:: Unix/macOS

.. code-block:: bash
python3 -m pip install --upgrade sphinx
.. tab:: Windows

.. code-block:: bat
py -m pip install --upgrade sphinx
For other installation methods, see this :doc:`installation guide <sphinx:usage/installation>` by Sphinx.


Getting Started With Sphinx
---------------------------

Create a ``docs`` directory inside your project to hold your documentation:

.. code-block:: bash
cd /path/to/project
mkdir docs
Run ``sphinx-quickstart`` inside the ``docs`` directory:

.. code-block:: bash
cd docs
sphinx-quickstart
This sets up a source directory, walks you through some basic configurations, and creates an ``index.rst`` file as well as a ``conf.py`` file.

You can add some information about your project in ``index.rst``, then build them:

.. code-block:: bash
make html
For more details on the build process, see this `guide`_ by Read The Docs.

.. _guide: https://docs.readthedocs.io/en/latest/intro/import-guide.html

Other Sources
-------------

For a more detailed guide on how to use Sphinx and reStructuredText, please see this `documentation tutorial`_ on Hitchhiker's Guide to Python.

.. _documentation tutorial: https://docs.python-guide.org/writing/documentation/
This tutorial has been removed since it is not related to packaging and was unmaintained.
Please see the `Sphinx tutorial <https://www.sphinx-doc.org/en/master/tutorial>`_ instead.
1 change: 0 additions & 1 deletion source/tutorials/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,3 @@ topics, see :doc:`/guides/index`.
installing-packages
managing-dependencies
packaging-projects
creating-documentation

0 comments on commit 870a1bc

Please sign in to comment.