mirror of
https://github.com/inventree/InvenTree.git
synced 2025-12-14 16:29:57 +00:00
Add information about building docs (#10998)
This commit is contained in:
@@ -15,6 +15,18 @@ $ git clone https://github.com/inventree/inventree
|
||||
$ pip install --require-hashes -r docs/requirements.txt
|
||||
```
|
||||
|
||||
## Build Documentation
|
||||
|
||||
Before serving the documentation, you will need to build the documentation files:
|
||||
|
||||
```
|
||||
invoke build-docs
|
||||
```
|
||||
|
||||
This is required to generate the required API schema files, and must be run before the documentation can be served.
|
||||
|
||||
Note that this command is only required when building the documentation for the first time, or when changes have been made to the API schema.
|
||||
|
||||
## Serve Locally
|
||||
|
||||
To serve the pages locally, run the following command (from the top-level project directory):
|
||||
@@ -23,6 +35,18 @@ To serve the pages locally, run the following command (from the top-level projec
|
||||
$ mkdocs serve -f docs/mkdocs.yml -a localhost:8080
|
||||
```
|
||||
|
||||
Alternatively, you can use the `invoke` command:
|
||||
|
||||
```
|
||||
invoke dev.docs-server
|
||||
```
|
||||
|
||||
To see all the available options:
|
||||
|
||||
```
|
||||
invoke dev.docs-server --help
|
||||
```
|
||||
|
||||
## Edit Documentation Files
|
||||
|
||||
Once the server is running, it will monitor the documentation files for any changes, and update the served pages.
|
||||
|
||||
Reference in New Issue
Block a user