Merge pull request #64 from Toakan/Readme-Update

Updated repo Readme
This commit is contained in:
Mark Drobnak
2018-10-17 00:17:33 -04:00
committed by GitHub
+21 -11
View File
@@ -1,18 +1,28 @@
If you want to work on this repo, you can preview the site as you work.
## Documentation & User Guides
Linux Mint / Ubuntu instructions:
This repo is the source for the official [Pi-hole documentation](https://docs.pi-hole.net/).
```
git clone git@github.com:pi-hole/docs.git
### How to contribute.
To add a new link on the navigation panel you need to edit the `mkdocs.yml` file in the root of the repo. There is a guide for building the navbar [on the mkdocs wiki]( https://www.mkdocs.org/user-guide/configuration/#nav)
To add a new document or guide.
- Navigate to the directory where it will be hosted.
EG. guides are in `docs/guides`
- Create the file using a URL friendly filename.
EG. `docs/guides/url-friendly.md`
- Edit your document using Markdown, there are loads of resources available for the correct syntax.
### Testing your changes.
Whilst working on this repo, it is advised that you review your own changes locally before commiting them. This can be done by using the `mkdocs serve` command.
Please make sure you fork the repo and change the clone URL in the example below for your fork:
```bash
git clone https://github.com/YOUR-USERNAME/docs
cd docs
sudo pip install mkdocs
sudo pip install mkdocs-material markdown-include
mkdocs serve --dev-addr 0.0.0.0:8000
```
Deploying to GitHub pages:
```
mkdocs gh-deploy
```
MkDocs will build the docs and use the `ghp-import` tool to commit them to our `gh-pages` branch and also automatically push the `gh-pages` branch to GitHub.
Warning: Be aware that you will not be able to review the built site before it is pushed to GitHub! Therefore, you **must** verify any changes you make to the docs beforehand by using the `mkdocs serve` command and reviewing the built files locally.