An example of setting up Sphinx and Doxygen for C++ and building with CMake and Read the Docs
Once homebrew, python3 and invoke package are installed (for OSX/Linux/WSL):
invoke install will do the trick and install all remaining required packages thru brew install ...
Activate the environment by running source activate.sh or activate.bat
This also compiles the code and the documentation on OSX/Linux/WSL.
Building the code as well as the documentation on UX: invoke build
Building the documentation on Windows: cd docs\ and make.bat.
To fix some dependencies: make clean
And sometimes: cmake --build .
Through invoke: invoke build --clean or invoke clean build
If you want to reuse this as a starting point for your development:
- Rename the virtual environment in
activate.*and adapt.gitignoreaccordingly - run
deactivate - remove the old virtual environment (
rm -rf .my\_super\_project) - activate again
CMakeLists.txt: To adapt the name of the CMake project (used as:@CMAKE_PROJECT_NAME@)docs/source/conf.py: Configuration of the Sphinx/Breathe documentationdocs/make.bat: Batchfile for native Windows buildsdocs/source/planning.uml: Title of the plan as shown on the first pagetasks.py: name of the app to run when usinginvoke run
The starting point of the generated documentation is actually in docs/sphinx/.
Shortcuts (called index.html) are made in the root and in docs/ which redirect there.
Viewing the documentation once built: invoke view