2021-07-25 12:26:45 +00:00
|
|
|
default:
|
|
|
|
|
2021-07-31 18:19:27 +00:00
|
|
|
lint:
|
|
|
|
golangci-lint run --timeout=5m
|
|
|
|
|
|
|
|
publish:
|
|
|
|
curl -sSLo golang.sh https://raw.githubusercontent.com/Luzifer/github-publish/master/golang.sh
|
|
|
|
bash golang.sh
|
|
|
|
|
|
|
|
test:
|
|
|
|
go test -cover -v .
|
|
|
|
|
|
|
|
# --- Documentation
|
|
|
|
|
2021-07-25 12:26:45 +00:00
|
|
|
gendoc: .venv
|
|
|
|
.venv/bin/python3 ci/gendoc.py $(shell grep -l '@module ' *.go) >wiki/Home.md
|
2021-07-25 13:02:54 +00:00
|
|
|
git add wiki/Home.md
|
2021-07-25 12:26:45 +00:00
|
|
|
|
|
|
|
.venv:
|
|
|
|
python -m venv .venv
|
|
|
|
.venv/bin/pip install -r ci/requirements.txt
|
|
|
|
|
|
|
|
# --- Wiki Updates
|
|
|
|
|
|
|
|
pull_wiki:
|
|
|
|
git subtree pull --prefix=wiki https://github.com/Luzifer/discord-community.wiki.git master --squash
|
|
|
|
|
|
|
|
push_wiki:
|
|
|
|
git subtree push --prefix=wiki https://github.com/Luzifer/discord-community.wiki.git master
|
2021-07-25 13:02:54 +00:00
|
|
|
|
|
|
|
# --- Local dev
|
|
|
|
|
|
|
|
auto-hook-pre-commit: gendoc
|
|
|
|
auto-hook-post-push: push_wiki
|