Files
Xen 7590df83de chore: add missing repo policy files (auto-enforced)
Applied 7 policy files via audit-repo-policies.sh.
Repo type: docs
Files: Makefile .editorconfig .prettierrc .prettierignore .dockerignore .gitignore tools/secret-scan.sh
2026-04-06 13:25:22 +00:00

40 lines
1.1 KiB
Makefile

BUMP ?= patch
.PHONY: check test lint fmt fmt-check secret-scan hooks release
check: lint fmt-check secret-scan test
test:
@echo "No tests configured for docs repo"
lint:
@echo "No linter configured for docs repo"
fmt:
@echo "No formatter configured for docs repo"
fmt-check:
@echo "No format check configured for docs repo"
secret-scan:
bash tools/secret-scan.sh .
hooks:
mkdir -p .git/hooks && printf '#!/bin/sh\nmake check' > .git/hooks/pre-commit && chmod +x .git/hooks/pre-commit
release:
@current=$$(git describe --tags --abbrev=0 2>/dev/null || echo "v0.0.0"); \
major=$$(echo $$current | sed 's/^v//' | cut -d. -f1); \
minor=$$(echo $$current | sed 's/^v//' | cut -d. -f2); \
patch=$$(echo $$current | sed 's/^v//' | cut -d. -f3); \
case "$(BUMP)" in \
major) major=$$((major+1)); minor=0; patch=0 ;; \
minor) minor=$$((minor+1)); patch=0 ;; \
patch) patch=$$((patch+1)) ;; \
*) echo "BUMP must be patch, minor, or major"; exit 1 ;; \
esac; \
next="v$$major.$$minor.$$patch"; \
echo "Tagging $$next (was $$current)"; \
git tag -a "$$next" -m "Release $$next"; \
git push origin "$$next"