This repository contains the source code of the documentation of BharatSim, an agent based modelling framework for India. This documentation is hosted on ReadTheDocs here.
The documentation uses Sphinx with the Sphinx-RTD theme. Read about Sphinx here.
If you plan on contributing to this documentation, get in touch with us at [email protected]. Then, fork
this repository on GitHub and make changes to your fork. Create and modify documentation pages inside the source
directory. You can then submit a pull request on GitHub. Your changes will then be merged after a review.
- Python 3 - Sphinx is based on Python, therefore you must have Python installed
- A Python package installer like
pip
orconda
The following commands will make a local copy of this repository, and install the required python packages.
- Clone the repository:
git clone [email protected]:bharatsim/documentation.git
- Move into the repository:
cd documentation
- Install requirements:
pip install -r requirements.txt
You can preview the final version of your local edits by building the HTML pages from your source. Note that this is only to check the final documentation. The build files should not be committed to version control. The final documentation site is built automatically from source files.
In order to build a local version of the HTML pages, navigate to within the repository and:
- If you have
make
installed, simply runmake html
- If not, run
sphinx-build -b html source build/html
You can now edit the source files and preview the results using any text editor. Sphinx uses reStructuredText, a "a simple, unobtrusive markup language" that will not take you too long to learn if you have not already used it.
If you wish, you can use a code editor like VS Code to edit the files, along with the reStructuredText plugin which includes many additional features, including a live preview.
This work is licensed under a Creative Commons Attribution-ShareAlike 4.0 International License.