Add tidy & update Makefile targets
This commit is contained in:
20
Makefile
20
Makefile
@@ -1,10 +1,10 @@
|
|||||||
SHELL := /usr/local/bin/oksh
|
SHELL := /bin/env oksh
|
||||||
export PATH := $(PATH)
|
export PATH := $(PATH)
|
||||||
|
|
||||||
all: fmt lintfix test clean build
|
all: fmt lintfix tidy test clean build
|
||||||
|
|
||||||
clean:
|
clean:
|
||||||
rm ./main
|
rm -f ./gemini-grc
|
||||||
|
|
||||||
debug:
|
debug:
|
||||||
@echo "PATH: $(PATH)"
|
@echo "PATH: $(PATH)"
|
||||||
@@ -18,6 +18,9 @@ debug:
|
|||||||
test:
|
test:
|
||||||
go test ./...
|
go test ./...
|
||||||
|
|
||||||
|
tidy:
|
||||||
|
go mod tidy
|
||||||
|
|
||||||
# Format code
|
# Format code
|
||||||
fmt:
|
fmt:
|
||||||
gofumpt -l -w .
|
gofumpt -l -w .
|
||||||
@@ -32,4 +35,13 @@ lintfix: fmt
|
|||||||
golangci-lint run --fix
|
golangci-lint run --fix
|
||||||
|
|
||||||
build:
|
build:
|
||||||
go build ./main.go
|
go build -o gemini-grc ./main.go
|
||||||
|
|
||||||
|
show-updates:
|
||||||
|
go list -m -u all
|
||||||
|
|
||||||
|
update:
|
||||||
|
go get -u all
|
||||||
|
|
||||||
|
update-patch:
|
||||||
|
go get -u=patch all
|
||||||
|
|||||||
Reference in New Issue
Block a user