add Makefile
This commit is contained in:
1 parent
e45f369356
commit
c021e8e6c2
3 files changed
+60
-2
No files matched your search
@@ -0,0 +1,22 @@
|
||||
BINARY=qulay
|
||||
SRC=main.go
|
||||
PREFIX=/usr
|
||||
|
||||
.PHONY: all clean install uninstall deps
|
||||
|
||||
all: deps
|
||||
go build -ldflags="-s -w" -o $(BINARY) $(SRC)
|
||||
|
||||
deps:
|
||||
go mod tidy
|
||||
|
||||
install: all
|
||||
install -Dm755 $(BINARY) $(PREFIX)/bin/$(BINARY)
|
||||
@echo "qulay installed to $(PREFIX)/bin"
|
||||
|
||||
uninstall:
|
||||
rm -f $(PREFIX)/bin/$(BINARY)
|
||||
@echo "qulay removed from $(PREFIX)/bin"
|
||||
|
||||
clean:
|
||||
rm -f $(BINARY)
|
||||
Reference in new issue
Block a user