-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
41 lines (32 loc) · 1.03 KB
/
Makefile
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
31
32
33
34
35
36
37
38
39
40
41
pkgname := haunt
build: ${pkgname}
${pkgname}: $(shell find . -name '*.go')
mkdir -p bin
go build -o bin/${pkgname} .
decode:
go run ./hack/unpack/main.go
pack-site:
go-bindata -pkg haunt -o src/haunt/bindata.go -fs assets/...
completions:
mkdir -p completions
./bin/${pkgname} completion zsh > completions/_${pkgname}
./bin/${pkgname} completion bash > completions/${pkgname}
./bin/${pkgname} completion fish > completions/${pkgname}.fish
run:
go run main.go
tidy:
go mod tidy
clean:
rm -rf bin
rm -rf completions
rm -rf assets
uninstall:
rm -f /usr/local/bin/${pkgname}
rm -f /usr/share/zsh/site-functions/_${pkgname}
rm -f /usr/share/bash-completion/completions/${pkgname}
rm -f /usr/share/fish/vendor_completions.d/${pkgname}.fish
install:
cp bin/${pkgname} /usr/local/bin
bin/${pkgname} completion zsh > /usr/share/zsh/site-functions/_${pkgname}
bin/${pkgname} completion bash > /usr/share/bash-completion/completions/${pkgname}
bin/${pkgname} completion fish > /usr/share/fish/vendor_completions.d/${pkgname}.fish