Skip to content

Commit b500662

Browse files
authored
Adding local launch script. (#5)
* Adding local launch script. * Switching from pyenv virtual env to python -m venv - whoops * Fixing link in README Signed-off-by: Olivia Buzek <ombuzek@us.ibm.com>
1 parent b0027fa commit b500662

File tree

2 files changed

+39
-0
lines changed

2 files changed

+39
-0
lines changed

README.md

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,27 @@
11
# docs.instructlab.ai
2+
3+
To test documentation changes locally, you'll need to install `mkdocs` and the relevant dependencies in your Python environment.
4+
5+
We've included a server launching script for ease of use.
6+
7+
## Getting Started
8+
9+
1. Create a virtual environment for your installation.
10+
11+
```bash
12+
python -m venv venv-ilab-docs
13+
source venv-ilab-docs/bin/activate
14+
```
15+
16+
2. Launch the server.
17+
18+
This will:
19+
* Install mkdocs
20+
* Install the PyPI dependencies
21+
* Launch the mkdocs server locally
22+
23+
```bash
24+
./launch_server.sh
25+
```
26+
27+
3. Visit [https://127.0.0.1:8000/](https://127.0.0.1:8000/) to see your changes in the browser.

launch_server.sh

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
#!/bin/bash
2+
3+
# You may want to activate a new virtual environment before running this script, as it will install Python dependencies.
4+
5+
pip install -U mkdocs
6+
7+
reqs=$(mkdocs get-deps)
8+
9+
echo "Installing: " $reqs
10+
pip install -U $reqs
11+
12+
echo "Starting server..."
13+
mkdocs serve

0 commit comments

Comments
 (0)