Skip to content

Creating rtd and doxygen documentations

Alper Altuntas edited this page Sep 17, 2019 · 1 revision

Step 0: Setting up your conda environment:

conda create -n mom6docs
source activate mom6docs
conda install doxygen
conda install -c anaconda graphviz
git clone https://github.com/angus-g/sphinx-fortran.git
( cd sphinx-fortran ; pip install -e . )
git clone https://github.com/angus-g/sphinxcontrib-autodoc_doxygen.git
( cd sphinxcontrib-autodoc_doxygen ; pip install -e . )

Step 1: * Download MOM6 code (dev/ncar):

git clone --recursive [email protected]:<YOUR_FORK_HERE>/MOM6.git
cd MOM6/docs
git checkout dev/ncar

Step 2: Create MOM6 documentation (readthedocs):

export NCAR_FORK=1
make Clean; make html

This will create the following html file (and others): _build/html/index.html To build this online, push your changes, go to readthedocs.org Projects, and build again. Make sure to set the branch and environment variable (NCAR_FORK) correctly.

Step 3: Create the complete API documentation (doxygen):

make Clean
doxygen ncar/Doxyfile_ncar_nortd

This will create the following file (and others): APIs/index.html You can then copy APIs to gh-pages branch and push to publish the results on Github pages of your MOM6 fork.

Step 3:

Clone this wiki locally