-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
30 lines (23 loc) · 839 Bytes
/
Copy pathMakefile
File metadata and controls
30 lines (23 loc) · 839 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
28
29
30
.DEFAULT_GOAL := help
.PHONY: build
build: ## Build public static files
zola --config config.toml build --output-dir docs --force
.PHONY: check
check: ## Check zola configuration
zola check
.PHONY: docker_build
docker_build: ## Build public static files with docker
docker run --rm -u "$(id -u):$(id -g)" -v $PWD:/app --workdir /app ghcr.io/getzola/zola:v0.22.1 build --force --output-dir docs
.PHONY: precommit
precommit: ## Fix code formatting and linting
pre-commit run --all-files
.PHONY: precommit_update
precommit_update: ## Update pre_commit
pre-commit autoupdate
.PHONY: run
run: ## Run zola run server
zola serve
.PHONY: help
help:
@echo "[Help] Makefile list commands:"
@grep -E '^[a-zA-Z_-]+:.*?## .*$$' $(MAKEFILE_LIST) | sort | awk 'BEGIN {FS = ":.*?## "}; {printf "\033[36m%-30s\033[0m %s\n", $$1, $$2}'