main
Makefile
Eric Bower
·
2026-05-16
1REV=$(shell git rev-parse --short HEAD)
2PROJECT="git-pgit-$(REV)"
3
4smol:
5 curl https://pico.sh/smol.css -o ./static/smol.css
6.PHONY: smol
7
8clean:
9 rm -rf ./public
10.PHONY: clean
11
12build:
13 go build -o pgit ./main.go
14.PHONY: build
15
16img:
17 docker build -t neurosnap/pgit:latest .
18.PHONY: img
19
20fmt:
21 go fmt ./...
22.PHONY: fmt
23
24lint:
25 golangci-lint run
26.PHONY: lint
27
28test:
29 go test ./...
30.PHONY: test
31
32static:
33 go run main.go \
34 --out ./public \
35 --label pgit \
36 --clone-url "https://github.com/picosh/pgit.git" \
37 --issues-url "https://github.com/picosh/pgit/issues" \
38 --contrib-url "https://github.com/picosh/pgit/pulls" \
39 --revs main \
40 --max-commits 10
41.PHONY: static
42
43dev: static
44 rsync -rv --delete ./public/ pgs.sh:/git-pgit-local/
45.PHONY: dev