summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorjwijenbergh <jeroenwijenbergh@protonmail.com>2024-07-02 13:02:13 +0200
committerjwijenbergh <jeroenwijenbergh@protonmail.com>2024-07-02 13:02:13 +0200
commit865532c2948345050184a139897b3e6253f11c11 (patch)
treea254bfb75529a8943b51fa7d55329eb2d1a7a54e /Makefile
parent3fb8bc94fdbc362f49bf211a3090358c70c26e8b (diff)
Makefile: Add a sloc target
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile5
1 files changed, 4 insertions, 1 deletions
diff --git a/Makefile b/Makefile
index cb5fb52..59e0556 100644
--- a/Makefile
+++ b/Makefile
@@ -1,5 +1,5 @@
.DEFAULT_GOAL := build
-.PHONY: build fmt cli clean coverage
+.PHONY: build fmt lint cli test clean coverage sloc
VERSION := $(shell grep -o 'const Version = "[^"]*' internal/version/version.go | cut -d '"' -f 2)
@@ -27,3 +27,6 @@ clean:
coverage:
go test -v -coverpkg=./... -coverprofile=common.cov ./...
go tool cover -func common.cov
+
+sloc:
+ tokei --exclude "*_test.go" -t=Go . || cloc --include-ext=go --not-match-f='_test.go' .