diff --git a/git/hooks/pre-commit b/git/hooks/pre-commit index a216261..6b8bf5b 100755 --- a/git/hooks/pre-commit +++ b/git/hooks/pre-commit @@ -56,8 +56,12 @@ while IFS= read -r -d '' file; do if [ -f "$file" ]; then size=$(wc -c < "$file") if [ "$size" -gt 5242880 ]; then - echo -e "${RED}Error: $file is larger than 5MB${NC}" - echo "Consider using Git LFS for large files" + echo -e "${RED}Error: $file is larger than 5 MiB (5,242,880 bytes)${NC}" + echo "This ceiling measures the working-tree file. Git LFS does not exempt it," + echo "and LFS was tried in this system and retired (chamber-library 0677e8a, 2026-06-05)." + echo "If this repo legitimately holds large files it needs its own hook:" + echo "copy .githooks from chamber-library (400c054), add the path exemption there," + echo "then: git config --local core.hooksPath .githooks" exit 1 fi fi