Add basic makefiles (#25)
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
close #24 Co-authored-by: Sam Therapy <sam@samtherapy.net> Co-authored-by: grumbulon <grumbulon@grumbulon.xyz> Reviewed-on: #25 Co-authored-by: Sam <sam@samtherapy.net> Co-committed-by: Sam <sam@samtherapy.net>
This commit is contained in:
parent
ed4d74bb96
commit
d31ad6e71a
2 changed files with 36 additions and 0 deletions
27
Makefile
Normal file
27
Makefile
Normal file
|
@ -0,0 +1,27 @@
|
|||
GO:=go
|
||||
GOFLAGS:= -ldflags '-s -w'
|
||||
PREFIX:=/usr/local
|
||||
BINPATH=$(PREFIX)/bin
|
||||
|
||||
# hehe
|
||||
all: awl
|
||||
|
||||
awl: .
|
||||
$(GO) build -o awl $(GOFLAGS) .
|
||||
|
||||
test:
|
||||
$(GO) test ./...
|
||||
|
||||
fmt:
|
||||
$(GO) fmt
|
||||
|
||||
vet:
|
||||
$(GO) vet
|
||||
|
||||
lint: fmt vet
|
||||
|
||||
install: awl
|
||||
install awl $(BINPATH) || echo "You probably need to run `sudo make install`"
|
||||
|
||||
clean:
|
||||
$(GO) clean
|
9
Mkfile
Normal file
9
Mkfile
Normal file
|
@ -0,0 +1,9 @@
|
|||
GO=GO
|
||||
awl: awl.go
|
||||
$GO build -o awl
|
||||
|
||||
install:
|
||||
$GO install .
|
||||
|
||||
test:
|
||||
$GO test ./...
|
Loading…
Reference in a new issue