diff options
author | Joey Hess <joey@kitenet.net> | 2012-06-02 18:17:22 -0400 |
---|---|---|
committer | Joey Hess <joey@kitenet.net> | 2012-06-02 18:17:22 -0400 |
commit | 83d18157ddfc2c1dabb3fca8918bedfb7d87420e (patch) | |
tree | fc2d8d5dc0a725243c0d2d414544b955e814d062 | |
parent | 6e7aab39cced00eae03040753c85527aab573319 (diff) |
fix indentation and remove a few probably too verbose messages
-rwxr-xr-x | uninit.d/50vcs-uninit | 18 |
1 files changed, 8 insertions, 10 deletions
diff --git a/uninit.d/50vcs-uninit b/uninit.d/50vcs-uninit index 165d415..803b0b5 100755 --- a/uninit.d/50vcs-uninit +++ b/uninit.d/50vcs-uninit @@ -18,19 +18,18 @@ fi managed_by_etckeeper="managed by etckeeper" if ! grep -q "$managed_by_etckeeper" "$file"; then - echo "etckeeper: "$file" does not contain \"$managed_by_etckeeper\" comment; not removing" exit 0 else realfile="$file" - if [ -n "`type -p tempfile`" ]; then - tempfile="tempfile" - elif [ -n "`type -p mktemp`" ]; then - tempfile="mktemp" - else - echo "etckeeper warning: can't find tempfile or mktemp" >&2 + if [ -n "`type -p tempfile`" ]; then + tempfile="tempfile" + elif [ -n "`type -p mktemp`" ]; then + tempfile="mktemp" + else + echo "etckeeper warning: can't find tempfile or mktemp" >&2 exit 1 - fi - file=$($tempfile) + fi + file=$($tempfile) otherentries= skipping= while read line; do @@ -47,7 +46,6 @@ else done <"$realfile" if [ "$otherentries" ]; then - echo "etckeeper: "$realfile" nonempty after \"$managed_by_etckeeper\" section removal; preserving other entries" mv -f "$file" "$realfile" else rm -f "$file" |