mirror of
https://gitee.com/johng/gf.git
synced 2024-11-29 18:57:44 +08:00
27 lines
408 B
Makefile
27 lines
408 B
Makefile
SHELL := /bin/bash
|
|
|
|
.PHONY: tidy
|
|
tidy:
|
|
$(eval files=$(shell find . -name go.mod))
|
|
@set -e; \
|
|
for file in ${files}; do \
|
|
goModPath=$$(dirname $$file); \
|
|
cd $$goModPath; \
|
|
go mod tidy; \
|
|
cd -; \
|
|
done
|
|
|
|
.PHONY: lint
|
|
lint:
|
|
golangci-lint run
|
|
|
|
# make version to=v2.4.0
|
|
.PHONY: version
|
|
version:
|
|
@set -e; \
|
|
newVersion=$(to); \
|
|
./.set_version.sh ./ $$newVersion; \
|
|
echo "make version to=$(to) done"
|
|
|
|
|