Skip to content

Commit

Permalink
update gitignore, add Makefile
Browse files Browse the repository at this point in the history
  • Loading branch information
Alessio Treglia committed Jul 28, 2023
1 parent 823e979 commit a792e00
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 0 deletions.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -26,3 +26,5 @@ _testmain.go
.idea/

escargs

config.hcl
25 changes: 25 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@

#!/usr/bin/make -f

VERSION := $(shell git describe)

all: build

build:
go build -a -v

install:
go install ./cmd/escargs

escargs: build
go build -v \
-ldflags="-X 'main.version=$(VERSION)'" \
./cmd/escargs

clean:
rm -rfv escargs

uninstall:
rm -v $(shell go env GOPATH)/bin/escargs

.PHONY: build clean install uninstall

0 comments on commit a792e00

Please sign in to comment.