2 title: Adding Documentation
5 The [documentation gerrit repository](https://gerrit.automotivelinux.org/gerrit/admin/repos/AGL/documentation) contains AGL documentation website template and content, rendering is visible at [https://docs-agl.readthedocs.io/en/latest/](https://docs-agl.readthedocs.io/en/latest/). The documentation site is hosted on [readthedocs](https://readthedocs.org/projects/docs-agl/) and corresponding builds are mentioned [here](https://readthedocs.org/projects/docs-agl/builds/).
10 Kindly check [this](https://wiki.automotivelinux.org/agl-distro/contributing) and clone with commit-msg hook :
13 $ git clone "ssh://$USER@gerrit.automotivelinux.org:29418/AGL/documentation" && scp -p -P 29418 $USER@gerrit.automotivelinux.org:hooks/commit-msg "documentation/.git/hooks/"
16 ## Building a local site
18 1. Change into the directory
24 2. Install MkDocs and rtd-dropdown theme
27 $ sudo pip install -r requirements.txt
30 3. Serve locally (defaultly rendered at [127.0.0.1:8000/](127.0.0.1:8000/)):
36 Process to **add new or edit existing** markdown files to AGL documentation:
38 ## Directory Structure
40 Find existing or add new markdowns in the following directory structure.
45 │ ├── 0_Getting_Started
47 │ │ └── 2_Building_AGL_Image
50 | ├──<Chapter-Number>_<Chapter-Name>
51 | | ├──<Subchapter-Number>_<Subchapter-Name>
52 | | | ├──<Index-Number>_<Markdown-Title>.md
56 ## Markdown Formatting
58 1. Add following at the start of each markdown :
69 [<enter-title>](../<Chapter-Number>_<Chapter-Name>/<Subchapter-Number>_<Subchapter-Name>/<Index-Number>_<Markdown-Title>.md)
74 [LinkChecker](https://wummel.github.io/linkchecker/) is a tool that allows to check all the hyperlinks in the site.
76 For testing hyperlinks as soon as the local site is running, do:
79 linkchecker http://localhost:8000
82 The ```linkchecker``` output will display the broken link and there location
91 #recent version of git-review (>=1.28.0 is required)
92 sudo pip3 install git-review
95 2. Write commit message
98 # track all the new changes
101 # Write the commit message
105 3. Push changes for review to Gerrit