summaryrefslogtreecommitdiff
path: root/pre-commit.d/10warn-hardlinks
blob: 3dd7a96e365faca7f955a493c6b84135bc57eeaf (plain)
1
2
3
4
5
6
7
#!/bin/sh
set -e
hardlinks=$(find -type f -not -links 1 | grep -v /.git/) || true
if [ -n "$hardlinks" ]; then
	echo "etckeeper warning: hardlinked files could cause problems with git:" >&2
	echo "$hardlinks" >&2
fi