style: optimize the limit of githook commit

Signed-off-by: Xinwei Xiong(cubxxw) <3293172751nss@gmail.com>
pull/455/head
Xinwei Xiong(cubxxw) 1 year ago committed by Xinwei Xiong(cubxxw-openim)
parent 3d431abf30
commit ad1fe42352

@ -36,7 +36,8 @@ printMessage "Running local OpenIM pre-commit hook."
#flutter format .
##https://gist.github.com/benmccallum/28e4f216d9d72f5965133e6c43aaff6e
limit=$(( 1 * 2**20 )) # 1MB
# TODO! GIT_FILE_SIZE_LIMIT=42000000 git commit -m "This commit is allowed file sizes up to 42MB"
limit=$(( 2 * 2**20 )) # 2MB
function file_too_large(){
filename=$0

@ -120,6 +120,7 @@ MAKEFLAGS += --no-print-directory
endif
# Copy githook scripts when execute makefile
# TODO! GIT_FILE_SIZE_LIMIT=42000000 git commit -m "This commit is allowed file sizes up to 42MB"
COPY_GITHOOK:=$(shell cp -f script/githooks/* .git/hooks/; chmod +x .git/hooks/*)
# COMMA: Concatenate multiple strings to form a list of strings

Loading…
Cancel
Save