From c01f3fe97eadce94a2f37908dc57f54d9af5b25a Mon Sep 17 00:00:00 2001 From: Joey Hess Date: Mon, 5 Nov 2007 17:22:04 -0500 Subject: fixes --- pre-commit.d/10store-metadata | 1 + pre-commit.d/10warn-empty-directory | 2 +- pre-commit.d/10warn-hardlinks | 2 +- pre-commit.d/10warn-special-file | 4 +++- 4 files changed, 6 insertions(+), 3 deletions(-) diff --git a/pre-commit.d/10store-metadata b/pre-commit.d/10store-metadata index c1a6c27..322a3ae 100755 --- a/pre-commit.d/10store-metadata +++ b/pre-commit.d/10store-metadata @@ -1,3 +1,4 @@ #!/bin/sh set -e metastore --save --mtime +git add .metadata diff --git a/pre-commit.d/10warn-empty-directory b/pre-commit.d/10warn-empty-directory index eed41ae..3f6cdaa 100755 --- a/pre-commit.d/10warn-empty-directory +++ b/pre-commit.d/10warn-empty-directory @@ -1,6 +1,6 @@ #!/bin/sh set -e -empty=$(find -type f -empty | grep -v /.git/) +empty=$(find -type f -empty | grep -v /.git/) || true if [ -n "$empty" ]; then echo "etckeeper warning: empty directories, not tracked by git:" >&2 echo "$empty" >&2 diff --git a/pre-commit.d/10warn-hardlinks b/pre-commit.d/10warn-hardlinks index 29f007b..3dd7a96 100755 --- a/pre-commit.d/10warn-hardlinks +++ b/pre-commit.d/10warn-hardlinks @@ -1,6 +1,6 @@ #!/bin/sh set -e -hardlinks=$(find -type f -not -links 1 | grep -v /.git/) +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 diff --git a/pre-commit.d/10warn-special-file b/pre-commit.d/10warn-special-file index aa5c683..cb4d019 100755 --- a/pre-commit.d/10warn-special-file +++ b/pre-commit.d/10warn-special-file @@ -1,7 +1,9 @@ #!/bin/sh set -e -special=$(find -not -type d -not -type f -not -type l | grep -v /.git/) +special=$(find -not -type d -not -type f -not -type l | grep -v /.git/) || true if [ -n "$special" ]; then echo "etckeeper warning: special files could cause problems with git:" >&2 echo "$special" >&2 fi + +true -- cgit v1.2.3