Green Navigation Docs
Installation Instructions
-
Clone this repository or download it as a .zip file and unzip.
-
Install gatsby (Python v2 is required!):
npm install -g gatsby
-
Go to repo directory. Checkout source branch first to make changes! Then install dependencies.
cd greennav.github.io git checkout source # Important !!! npm install
-
Start gatsby server:
gatsby develop
-
Open site in browser at
localhost:8000
and make your changes.
Edit Documentation
-
Each page is in its own markdown file in the pages directory. If you want to make changes to a page, just edit the corresponding Markdown file.
-
There are three main categories:
- docs
- development
- news
-
To add a new page, create a new markdown file in the corresponding pages directory.
-
With gatsby it is also possible to write html, js or even json code to present content. For further information go to GatsbyJS-Docs
-
Note that the documentation repo is ready for material-ui! So if you want to use any component, do it!
-
After editing any content make a pull-request. Remember that you are still on source branch. That's fine! If we will accept your PR, we will publish your changes to master branch.
Note: The following instructions are only relevant for members with write access to the repository!
Build and Deploy
-
If you are done and satisfied with your work commit and push your changes.
-
Build the documentation with:
gatsby build --prefix-links
-
The project will now build to public directory. Remember that you are still on source branch. That's fine! All you have to do now is to move the content of public to the root of the master branch and commit and push again (now from master branch). That's it.