The current documentation repo is https://github.com/uc-cdis/vadc-mkdocs (this is the one that is live on the platform)
Documentation for VA is usually written in a markdown or google drive file. The steps of converting markdown/google drive/word/etc files to HTML is currently as folows.
- Convert documentation into markdown format if its not currently in markdown format
- Convert markdown to rst format via pandocs
- Convert rst to HTML via sphinx
Separate virtual environment is recommended for building documentation:
- Create virtual environment in the cloned repository.
python3 -m venv venv
- Activate virtual environment.
source venv/bin/activate
- Install required packages.
python3 -m pip install -r requirements.txt
- Use sphinx:
sphinx-build -b html source build
- Use official instruction
- Homebrew
sphinx-doc
package:
brew install sphinx-doc
- Use
./docs/
as a main working directory. - Write any documentation pages in the
source
directory. Use markdown format only. - Run
make html
to generate build directory with documentation. - Check the result of the build in the
build
directory. Thehtml/index.html
file is the main page of the documentation. - Run
deactivate
when finished working with documentation.
- Having either gitops-qa (for QA) or cdis-manifest (for pre-prod/prod).
- Run
make html
to generate build directory with documentation. - Copy the documentation to either
gitops-qa
/cdis-manifest
repositories. For example, for QA, assuming thatgitops-qa
is in the same directory asva-doc
repository, WARNING this step will remove all files in the destination directory and copy all files from the source directory:
make copy DEST_DIR=../../gitops-qa/qa-mickey.planx-pla.net/dashboard/Public/documentation/
- Commit and push the changes to the repository, either
gitops-qa
orcdis-manifest
. - For next steps refer to the
dashboard
documentation: https://github.com/uc-cdis/cdis-wiki/blob/master/onboarding/services/dashboard.md.