-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
27 lines (20 loc) · 794 Bytes
/
Makefile
File metadata and controls
27 lines (20 loc) · 794 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
SHELL := /bin/bash
PYTHON ?= python3
MKDOCS ?= mkdocs
PORT ?= 8080
.PHONY: help install build serve clean distclean
help: ## Show this help
@grep -E '^[a-zA-Z_-]+:.*?## .*$$' $(MAKEFILE_LIST) | \
awk 'BEGIN {FS = ":.*?## "}; {printf " %-14s %s\n", $$1, $$2}'
install: ## Install Python dependencies
$(PYTHON) -m pip install -r requirements.txt
build: ## Build the static site into site/
$(MKDOCS) build
serve: ## Start the dev server on PORT (default 8080)
$(MKDOCS) serve --dev-addr localhost:$(PORT)
clean: ## Remove build artifacts
rm -rf site/
distclean: clean ## Remove build artifacts and Python caches
rm -rf __pycache__ .cache
find . -type d -name __pycache__ -exec rm -rf {} + 2>/dev/null || true
find . -type f -name '*.pyc' -delete 2>/dev/null || true