ttr.git


ttr

~ tiny traceroute in golang
git clone https://github.com/djnnvx/ttr.git
log | files | refs | archive | README | LICENSE

Makefile (634B)

      1 TARGET 		= ttr
      2 SRC 		= main.go
      3 
      4 
      5 .PHONY: all
      6 all: compile
      7 
      8 .PHONY: help
      9 help:
     10 	@echo "\033[34mttr targets:\033[0m"
     11 	@perl -nle'print $& if m{^[a-zA-Z_-\d]+:.*?## .*$$}' $(MAKEFILE_LIST) | sort | awk 'BEGIN {FS = ":.*?## "}; {printf "\033[36m%-22s\033[0m %s\n", $$1, $$2}'
     12 
     13 .PHONY: compile
     14 compile: ## compile the project
     15 	@go build -o $(TARGET) $(SRC)
     16 
     17 .PHONY: clean
     18 clean: ## cleans up the project
     19 	rm -f $(TARGET)
     20 
     21 .PHONY: tidy
     22 tidy: ## runs tidy and formatting
     23 	@go mod tidy
     24 	@gofmt -s -w .
     25 
     26 .PHONY: release-build
     27 release-build: ## makes a release build locally on the current commit
     28 	@goreleaser release --skip=publish --snapshot