hmdeploy/Makefile
2025-04-29 16:20:50 +02:00

18 lines
453 B
Makefile

BIN_NAME = "hmdeploy"
BIN_INSTALL = $(shell whereis $(BIN_NAME) | cut -d ' ' -f2 | xargs rm -f)
run: lint
@go run main.go
build: lint
@echo "building binary..."
@go build -ldflags "-X main.Version=0.1.0" -o $(BIN_NAME) main.go && echo "$(BIN_NAME) built"
install: build
@mv $(BIN_NAME) $(GOPATH)/bin/hmdeploy
@echo "program installed: $(GOPATH)/bin/hmdeploy"
lint:
@echo "format and lint..."
@golangci-lint fmt ./...
@golangci-lint run ./...