Check if /etc/.git has the proper rights

This commit is contained in:
Tristan PILAT 2019-03-22 15:00:40 +01:00
parent 8ae3707044
commit 950ea6fca6

View file

@ -196,6 +196,9 @@ fi
# Check if /etc/.git/ has read/write permissions for root only.
if [ "$IS_GITPERMS" = 1 ]; then
test -d /etc/.git && [ "$(stat -f %p /etc/.git/)" = "40700" ] || echo 'IS_GITPERMS FAILED!'
if [[ "$VERBOSE" == 1 ]]; then
echo "The directiry /etc/.git sould be in 700"
fi
fi