From e443ea4d395b36a9d64ddfad2d805b4fa59a1b92 Mon Sep 17 00:00:00 2001 From: curo1305 Date: Mon, 13 Apr 2026 23:08:37 +0200 Subject: [PATCH] Disable pip cache in pre-commit container MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit /.cache/pip is owned by root; as UID 1001 pip emits a cache-permission warning. Container is ephemeral so caching has no value — disable it with PIP_NO_CACHE_DIR=1. Co-Authored-By: Claude Sonnet 4.6 --- .githooks/pre-commit | 1 + 1 file changed, 1 insertion(+) diff --git a/.githooks/pre-commit b/.githooks/pre-commit index 3f49670..7f06559 100755 --- a/.githooks/pre-commit +++ b/.githooks/pre-commit @@ -21,6 +21,7 @@ docker run --rm \ -e STAGED_FILES="$STAGED" \ -u 1001:1001 \ -e PIP_DISABLE_PIP_VERSION_CHECK=1 \ + -e PIP_NO_CACHE_DIR=1 \ python:3.12-slim \ sh -c "python -m venv /tmp/venv && /tmp/venv/bin/pip install --quiet bandit && /tmp/venv/bin/python scripts/security_check.py"