Makefile 352 B

123456789101112131415161718192021
  1. .PHONY: build format test
  2. KYOKETSU = kyoketsu
  3. build:
  4. go build -o ./build/linux/$(KYOKETSU)/$(KYOKETSU) ./cmd/$(KYOKETSU)/$(KYOKETSU).go
  5. format:
  6. go fmt ./...
  7. install:
  8. sudo rm -f /usr/local/bin/$(KYOKETSU) && \
  9. sudo mv ./build/linux/$(KYOKETSU)/$(KYOKETSU) /usr/local/bin && sudo chmod u+x /usr/local/bin/$(KYOKETSU)
  10. test:
  11. go test ./...