fix: add golangci-lint to pre-commit hook, clarify R2_ENDPOINT in env example

Pre-commit now runs golangci-lint (3m timeout) after go vet, before staticcheck. R2_ENDPOINT comment updated to clarify it is prod-only and local dev uses S3_* vars.

Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent)

Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
This commit is contained in:
2026-07-11 14:12:28 +01:00
co-authored by Sisyphus
parent b549014a68
commit 85c043ad7f
2 changed files with 9 additions and 1 deletions
+7
View File
@@ -41,6 +41,13 @@ if [ -n "$BACKEND_FILES" ]; then
fi
cd ..
printf "${YELLOW}Checking golangci-lint...${NC}\n"
if ! cd backend && golangci-lint run ./... --timeout 3m 2>&1; then
printf "${RED}✖ golangci-lint failed${NC}\n"
FAILED=1
fi
cd ..
printf "${YELLOW}Checking staticcheck...${NC}\n"
if ! cd backend && staticcheck -tags "test,dev" ./... 2>&1; then
printf "${RED}✖ staticcheck failed${NC}\n"