Before you are able to run this locally you need to have NodeJS v8.x, YARN and Hugo installed on your machine. If you already have Hugo installed, make sure you have the latest version.
-
Install project dependencies
make install
-
Back in the root of the project, run
make build
-
And then run the project
make serve
-
In your browser navigate to
localhost:1313
to view the project.
Help center can be built for either staging or prod via:
make build-prod
make serve-prod
make build-staging
make serve-staging
Included in this project is the hugo-algolia package, which crawls the /content folder of the site and indexes all the content. If you want to re-index the site and/or send new docs content to Algolia, you can use the following commands:
This command indexes the whole site and puts content into a single array.
make index-site
This command indexes the whole site and sends the array to Algolia.
make index-and-send
You can index and send content to our staging indices via:
make index-and-send-staging
Simply put the following shortcode after the front matter and before the main page content (or wherever you want the alert to appear) and replace the URL with the URL to the desired article.
{{< kotsdocs "https://kots.io" >}}