Skip to content

Commit

Permalink
Update docs on docs about docs (#1360)
Browse files Browse the repository at this point in the history
  • Loading branch information
mcm001 authored Jul 4, 2024
1 parent fab7591 commit 9ad9b82
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 24 deletions.
2 changes: 1 addition & 1 deletion .readthedocs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ build:
# If there are no changes (git diff exits with 0) we force the command to return with 183.
# This is a special exit code on Read the Docs that will cancel the build immediately.
- |
if [ "$READTHEDOCS_VERSION_TYPE" = "external" ] && git diff --quiet origin/master -- docs/ docs/.readthedocs.yaml;
if [ "$READTHEDOCS_VERSION_TYPE" = "external" ] && git diff --quiet origin/master -- docs/ .readthedocs.yaml;
then
exit 183;
fi
Expand Down
15 changes: 0 additions & 15 deletions docs/.readthedocs.yaml

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -4,29 +4,30 @@ To build the PhotonVision documentation, you will require `Git <https://git-scm.

Cloning the Documentation Repository
------------------------------------
If you are planning on contributing, it is recommended to create a fork of the `main docs repository <https://github.com/PhotonVision/photonvision-docs>`_. To clone this fork, run the following command in a terminal window:

``git clone https://github.com/[your username]/photonvision-docs``
Documentation lives within the main PhotonVision repository within the `docs` sub-folder. If you are planning on contributing, it is recommended to create a fork of the `PhotonVision repository <https://github.com/PhotonVision/photonvision>`_. To clone this fork, run the following command in a terminal window:

``git clone https://github.com/[your username]/photonvision``

Installing Python Dependencies
------------------------------
You must install a set of Python dependencies in order to build the documentation. To do so, you can run the following command in the root project directory:
You must install a set of Python dependencies in order to build the documentation. To do so, you can run the following command in the docs sub-folder:

``python -m pip install -r requirements.txt``
``~/photonvision/docs$ python -m pip install -r requirements.txt``

Building the Documentation
--------------------------
In order to build the documentation, you can run the following command in the root project directory:
In order to build the documentation, you can run the following command in the docs sub-folder:

``make html``
``~/photonvision/docs$ make html``

.. note:: You may have to run ``./make html`` on Windows.

Opening the Documentation
-------------------------
The built documentation is located at ``build/html/index.html``.
The built documentation is located at ``docs/build/html/index.html`` relative to the root project directory.

Docs Builds on Pull Requests
----------------------------

Pre-merge builds of docs can be found at: ``https://photonvision-docs--PRNUMBER.org.readthedocs.build/en/PRNUMBER/index.html``. These docs are republished on every commit to a pull request made to PhotonVision/photonvision-docs. For example, PR 325 would have pre-merge documentation published to ``https://photonvision-docs--325.org.readthedocs.build/en/325/index.html``
Pre-merge builds of docs can be found at: ``https://photonvision-docs--PRNUMBER.org.readthedocs.build/en/PRNUMBER/index.html``. These docs are republished on every commit to a pull request made to PhotonVision/photonvision-docs. For example, PR 325 would have pre-merge documentation published to ``https://photonvision-docs--325.org.readthedocs.build/en/325/index.html``. Additionally, the pull requrest will have a link directly to the pre-release build of the docs. This build only runs when there is a change to files in the docs sub-folder.

0 comments on commit 9ad9b82

Please sign in to comment.