-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Update docstring and other modules documentations. * Documentation improved
- Loading branch information
1 parent
40f4b7a
commit 99786b4
Showing
15 changed files
with
421 additions
and
144 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,41 +1,49 @@ | ||
=================== | ||
⚙API documentation | ||
=================== | ||
================= | ||
API documentation | ||
================= | ||
|
||
main | ||
---- | ||
Entry application | ||
----------------- | ||
|
||
The entry point for the package ``sphinx-versioned-docs`` is through :func:`sphinx_versioned.__main__.main`. | ||
The function is actually a Typer CLI with the various command-line options available. | ||
|
||
.. automodule:: sphinx_versioned.__main__ | ||
:members: | ||
:undoc-members: | ||
:private-members: | ||
:show-inheritance: | ||
|
||
---------- | ||
|
||
sphinx extension | ||
Building workflow | ||
----------------- | ||
|
||
.. automodule:: sphinx_versioned.build | ||
:members: | ||
:private-members: | ||
:show-inheritance: | ||
|
||
Sphinx extension | ||
---------------- | ||
|
||
The sphinx-extension is added by default on running ``sphinx-versioned`` to inject the versions flyout | ||
menu directly to the html files. | ||
|
||
.. automodule:: sphinx_versioned.sphinx_ | ||
:members: | ||
:undoc-members: | ||
:private-members: | ||
:show-inheritance: | ||
|
||
---------- | ||
------------------------------------------- | ||
|
||
versions container | ||
------------------ | ||
Utiliies/ Libraries | ||
------------------- | ||
|
||
.. automodule:: sphinx_versioned.versions | ||
:members: | ||
:undoc-members: | ||
:private-members: | ||
:show-inheritance: | ||
|
||
---------- | ||
|
||
util | ||
---- | ||
|
||
.. automodule:: sphinx_versioned.lib | ||
:members: | ||
:undoc-members: | ||
:private-members: | ||
:show-inheritance: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
Improved package-wide documentation. Added doc-strings and improved tutorial and installation instructions for fresh users. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,85 @@ | ||
.. _settings: | ||
|
||
======== | ||
Settings | ||
======== | ||
|
||
.. code-block:: | ||
sphinx-versioned [OPTIONS] | ||
The ``sphinx-versioned-docs`` reads options from two sources: | ||
|
||
* From the sphinx ``conf.py`` file. | ||
* From the provided command-line-arguments. | ||
|
||
Configuration File Arguments | ||
============================ | ||
|
||
Currently, only the ``sv_project_url`` can be set via the ``conf.py``. More options coming in future releases. | ||
|
||
.. option:: sv_project_url: <url> | ||
|
||
Setting this variable will make sure that the ``Project home`` is listed on the versions selector badge/menu. | ||
|
||
Command Line Arguments | ||
====================== | ||
|
||
These command line options must be specified when executing the ``sphinx-versioned`` command. | ||
|
||
.. option:: -c <directory>, --chdir <directory> | ||
|
||
Change the current working directory. | ||
|
||
.. option:: --git-root <directory> | ||
|
||
Path to the git-root of the current repo. Default is the current working directory. | ||
|
||
.. option:: -o <directory>, --output <directory> | ||
|
||
Set the output directory. | ||
|
||
.. option:: --local-conf <directory> | ||
|
||
Path to the ``conf.py`` for ``sphinx-versioned``. Default is ``conf.py`` at the current working directory. | ||
|
||
.. option:: --reset-intersphinx | ||
|
||
Resets intersphinx mapping; acts as a patch for issue `#17 <https://github.com/devanshshukla99/sphinx-versioned-docs/issues/17>`__. Default is `False`. | ||
|
||
.. option:: --sphinx-compability | ||
|
||
Adds compatibility for older sphinx versions by monkey patching certain functions. Default is `False`. | ||
|
||
.. option:: --prebuild, --no-prebuild | ||
|
||
Pre-build all versions to make sure ``sphinx-build`` has no issues and pass-on the successful builds to ``sphinx-versioned-docs``. Default is `True`. | ||
|
||
.. option:: -b <branch names separated by `,` or `|`>, --branches <branch names separated by `,` or `|`> | ||
|
||
Build docs and the version selector menu only for certain tags and branches. | ||
|
||
.. option:: -m <branch name>, --main-branch <branch name> | ||
|
||
Specify the main-branch to which the top-level ``index.html`` redirects to. Default is ``main``. | ||
|
||
.. option:: --quite, --no-quite | ||
|
||
Silents the output from `sphinx`. Use `--no-quite` to get complete-output from `sphinx`. Default is `True`. | ||
|
||
.. option:: -v, --verbose | ||
|
||
Passed directly to sphinx. Specify more than once for more logging in sphinx. Default is `False`. | ||
|
||
.. option:: -log <level>, --log <level> | ||
|
||
Provide logging level. Example `--log` debug, Default is ``info``. | ||
Logging levels can be ``trace``, ``debug``, ``warn``, ``info``, etc. | ||
|
||
.. option:: --force | ||
|
||
Force branch selection. Use this option to build detached head/commits. Default is `False`. | ||
|
||
.. option:: --help | ||
|
||
Show the help message in command-line. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.