Skip to content

Commit 860d7ca

Browse files
committed
clean up Mark's initial docs work
1 parent 6229fc6 commit 860d7ca

20 files changed

+33
-593
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,7 @@ wheels/
5656
*.egg
5757
MANIFEST
5858
.cache/*
59+
docs/.cache/*
5960

6061
# PyInstaller
6162
# Usually these files are written by a python script from a template

.readthedocs.yaml

Lines changed: 0 additions & 22 deletions
This file was deleted.

docs/Makefile

Lines changed: 19 additions & 42 deletions
Original file line numberDiff line numberDiff line change
@@ -1,50 +1,27 @@
1-
# Minimal makefile for Sphinx documentation
1+
# Minimal mkdocs makefile
22

3-
# You can set these variables from the command line, and also
4-
# from the environment for the first two.
5-
SPHINXOPTS ?=
6-
SPHINXBUILD ?= sphinx-build
7-
SOURCEDIR = source
8-
BUILDDIR = build
3+
PYTHON := python3
4+
REQS := requirements.txt
5+
MKDOCS_CMD := mkdocs
6+
MKDOCS_CONF := ../mkdocs.yml
97

10-
EXAMPLES_SRC = ../examples
11-
EXAMPLES_DST = $(SOURCEDIR)/doc
8+
.PHONY: help install serve build clean
129

13-
.PHONY: help Makefile clean update-examples html
14-
15-
# Default target
1610
help:
17-
@$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
11+
@echo "Available targets:"
12+
@echo " install Install dependencies globally"
13+
@echo " serve Serve docs locally"
14+
@echo " build Build static site"
15+
@echo " clean Remove build artifacts"
1816

19-
# Clean build and copied example files
20-
clean:
21-
@$(SPHINXBUILD) -M clean "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
22-
rm -rf $(EXAMPLES_DST)
17+
install:
18+
pip install -r $(REQS)
2319

24-
# Copies .md files from ../examples/ to source/doc/, and updates docs/examples.md
25-
update-examples:
26-
rm -rf $(EXAMPLES_DST)
27-
mkdir -p $(EXAMPLES_DST)
28-
DOCS_ROOT=$$(pwd); \
29-
cd $(EXAMPLES_SRC) && find . -name '*.md' -type f -exec sh -c ' \
30-
DOCS_ROOT="'"$$DOCS_ROOT"'"; \
31-
EXAMPLES_DST="'"$(EXAMPLES_DST)"'"; \
32-
for f; do \
33-
mkdir -p "$$DOCS_ROOT/$$EXAMPLES_DST/$$(dirname "$$f")"; \
34-
cp "$$f" "$$DOCS_ROOT/$$EXAMPLES_DST/$$f"; \
35-
done' sh {} +
36-
@echo "Generating source/examples.md..."
37-
@./scripts/copy-example-docs.sh
20+
serve:
21+
$(MKDOCS_CMD) serve --livereload -f $(MKDOCS_CONF)
3822

39-
# Build docs and optionally serve locally
40-
html: clean update-examples
41-
@$(SPHINXBUILD) -M html "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
42-
@if [ -z "$$CI" ]; then \
43-
echo "Starting local HTTP server at http://localhost:8000"; \
44-
python3 -m http.server --directory $(BUILDDIR)/html; \
45-
fi
23+
build:
24+
$(MKDOCS_CMD) build -f $(MKDOCS_CONF)
4625

47-
# Catch-all target: route all unknown targets to Sphinx using the new
48-
# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS).
49-
%: Makefile
50-
@$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
26+
clean:
27+
rm -rf site/ .cache/

docs/requirements.txt

Lines changed: 12 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -1,26 +1,12 @@
1-
sphinx==6.2.1
2-
sphinx-argparse==0.4.0
3-
sphinx-book-theme==1.0.1
4-
sphinx-copybutton==0.5.2
5-
sphinx-design==0.6.1
6-
sphinx-togglebutton==0.3.2
7-
myst-parser==3.0.1
8-
msgspec
9-
cloudpickle
10-
11-
# packages to install to build the documentation
12-
cachetools
13-
pydantic >= 2.8
14-
-f https://download.pytorch.org/whl/cpu
15-
torch
16-
py-cpuinfo
17-
transformers
18-
mistral_common >= 1.5.4
19-
aiohttp
20-
sphinx-autodoc2
21-
starlette
22-
openai # Required by docs/source/serving/openai_compatible_server.md's vllm.entrypoints.openai.cli_args
23-
fastapi # Required by docs/source/serving/openai_compatible_server.md's vllm.entrypoints.openai.cli_args
24-
partial-json-parser # Required by docs/source/serving/openai_compatible_server.md's vllm.entrypoints.openai.cli_args
25-
requests
26-
zmq
1+
markdown
2+
mike
3+
mkdocs
4+
mkdocs-api-autonav
5+
mkdocs-gen-files
6+
mkdocs-material
7+
mkdocs-material[imaging]
8+
mkdocs-minify-plugin
9+
mkdocs-nav-weight
10+
mkdocs-section-index
11+
mkdocstrings-python
12+
pymdown-extensions

docs/scripts/copy-example-docs.sh

Lines changed: 0 additions & 20 deletions
This file was deleted.

docs/source/_static/custom.css

Lines changed: 0 additions & 8 deletions
This file was deleted.

docs/source/_static/custom.js

Lines changed: 0 additions & 38 deletions
This file was deleted.

docs/source/_templates/sections/header.html

Lines changed: 0 additions & 39 deletions
This file was deleted.

docs/source/about.md

Lines changed: 0 additions & 7 deletions
This file was deleted.

docs/source/assets/_static/custom.css

Lines changed: 0 additions & 8 deletions
This file was deleted.

0 commit comments

Comments
 (0)