make: add cache directory for linter

Mounts a local temporary folder to the linter docker container in order
to persist the linter cache across runs.
This commit is contained in:
bitromortac 2024-04-26 13:21:25 +02:00
parent e6d6789fd9
commit ba34f220b9
No known key found for this signature in database
GPG key ID: 1965063FC13BEBE2

View file

@ -69,6 +69,7 @@ DOCKER_TOOLS = docker run \
--rm \
-v $(shell bash -c "go env GOCACHE || (mkdir -p /tmp/go-cache; echo /tmp/go-cache)"):/tmp/build/.cache \
-v $(shell bash -c "go env GOMODCACHE || (mkdir -p /tmp/go-modcache; echo /tmp/go-modcache)"):/tmp/build/.modcache \
-v $(shell bash -c "mkdir -p /tmp/go-lint-cache; echo /tmp/go-lint-cache"):/root/.cache/golangci-lint \
-v $$(pwd):/build lnd-tools
GREEN := "\\033[0;32m"