new-horizons/docs/Setup.md
Ben C 61cdb1b9f5
Update Documentation Site (#54)
* Add Bootstrap Extension

* Rename main.yml

* Artifact Upload

* Fix Bootstrap Reference Error

* BootstrapTreeProcessor

* getiterator removed

* keys function

* Style Images

* Update docs_build.yml

* Added Meta Files

* Template Get

* Fix Page Ref

* Update BASE_URL

* Sort Schemas

* Add Sitemaps

* Add favicons, open-graph, and setup guide

* Update Setup.md

* Update .gitignore

* Update Setup.md
2022-03-03 17:08:06 -08:00

48 lines
1.3 KiB
Markdown

# Setup to build docs
## Requirements
- Python 3.10
## Clone the repo
Clone the entire repo and navigate to the docs folder
```shell
git clone https://github.com/xen-42/outer-wilds-new-horizons
cd outer-wilds-new-horizons/docs
```
## Setup Pipenv
Install pipenv if you haven't already
```shell
pip install --user pipenv
```
Install dependencies
```shell
pipenv install
```
## Environment Variables
- OUT_DIR: Path to put before all links and static files, see below for recommended values
- Production: "/"
- Local Build: "" (set as empty string)
- PyCharm Development Server: "/outer-wilds-new-horizons/docs/out/"
- BASE_URL: Base url of the website we're hosting on
- Local: Leave blank
- Local (but wanting to test open-graph/twitter): "https://nh.outerwildsmods.com/"
- Production: "https://nh.outerwildsmods.com/"
## Copy Schemas
Create a folder called `schemas` in the content folder and copy all schemas to generate into it, make sure not to add this folder to git.
Production build automatically copies over schemas.
## Generating
Run `generate.py` with pipenv
```shell
pipenv run python generate.py
```
## Opening
- Production: Go to the site
- Local: Open `out/index.html`
- PyCharm Development Server: Right click `out/index.html` -> Open In -> Browser -> Default