Building the Website¶
For developers who want to contribute to the website/documentation of Directional. If you want to preview changes to the Directional website before a commit, you can follow the instructions below.
Prerequisites¶
- If you do not already have it, install conda on your machine. We recommend using miniconda3. On Linux you can run:
wget https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.sh bash Miniconda3-latest-Linux-x86_64.sh
- Install the conda environment for the website:
conda env create -f directional-website.yml
Using mkdocs¶
- Activate the conda environment installed on the previous step:
conda activate directional-website
- Preview the website locally
(run this command in the root folder of the Directional repository):
mkdocs serve
Tip
Note
The reason we are using python -m mkdocs serve
instead of mkdocs serve
directly is because we are using local extensions for mkdocs. Those extensions are located in the scripts/
folder of libigl. Running mkdocs
as a module adds the current directory to the PYTHONPATH
, allowing us to load those extensions without installing them on the system or in a virtualenv.