Merge pull request 'Docs: Change docs README for new way of building docs' (#448...
authorfloatingghost <hannah@coffee-and-dreams.uk>
Sun, 26 Feb 2023 21:49:42 +0000 (21:49 +0000)
committerfloatingghost <hannah@coffee-and-dreams.uk>
Sun, 26 Feb 2023 21:49:42 +0000 (21:49 +0000)
Reviewed-on: https://akkoma.dev/AkkomaGang/akkoma/pulls/448

.gitignore
Makefile [deleted file]
docs/README.md

index 95b236af62e286baa85790f5d0b8b51d31e6c984..8821d8ce106287131f48d61fb323aef91b346956 100644 (file)
@@ -73,6 +73,7 @@ pleroma.iml
 
 # Generated documentation
 docs/site
+docs/venv
 
 # docker stuff
 docker-db
diff --git a/Makefile b/Makefile
deleted file mode 100644 (file)
index bc8719e..0000000
--- a/Makefile
+++ /dev/null
@@ -1,7 +0,0 @@
-all:   install
-       pipenv run mkdocs build
-
-install:
-       pipenv install
-clean:
-       rm -rf docs
index fcf043f5619d3f2960d371c49faffffbcaa345d4..3da3d1967dae52fbeb6baa54bea66f85443aa82d 100644 (file)
@@ -2,33 +2,27 @@
 
 You don't need to build and test the docs as long as you make sure the syntax is correct. But in case you do want to build the docs, feel free to do so.
 
-You'll need to install mkdocs for which you can check the [mkdocs installation guide](https://www.mkdocs.org/#installation). Generally it's best to install it using `pip`. You'll also need to install the correct dependencies.
+```sh
+# Make sure you're in the same directory as this README
+# From the root of the Akkoma repo, you'll need to do
+cd docs
 
-### Example using a Debian based distro
+# Optionally use a virtual environment
+python3 -m venv venv
+source venv/bin/activate
 
-#### 1. Install pipenv and dependencies
+# Install dependencies
+pip install -r requirements.txt
 
-```shell
-pip install pipenv
-pipenv sync
-```
-
-#### 2. (Optional) Activate the virtual environment
-
-Since dependencies are installed in a virtual environment, you can't use them directly. To use them you should either prefix the command with `pipenv run`, or activate the virtual environment for current shell by executing `pipenv shell` once.
-
-#### 3. Build the docs using the script
+# Run an http server who rebuilds when files change
+# Accessable on http://127.0.0.1:8000
+mkdocs serve
 
-```shell
-[pipenv run] make all
-```
-
-#### 4. Serve the files
+# Build the docs
+# The static html pages will have been created in the folder "site"
+# You can serve them from a server by pointing your server software (nginx, apache...) to this location
+mkdocs build
 
-A folder `site` containing the static html pages will have been created. You can serve them from a server by pointing your server software (nginx, apache...) to this location. During development, you can run locally with
-
-```shell
-[pipenv run] mkdocs serve
+# To get out of the virtual environment, you do
+deactivate
 ```
-
-This handles setting up an http server and rebuilding when files change. You can then access the docs on <http://127.0.0.1:8000>