From f71413176f32ef642824456544ecbda5933a0944 Mon Sep 17 00:00:00 2001 From: Ben Longbons Date: Mon, 23 Dec 2013 19:40:38 -0800 Subject: Add non-indenting indenter for C++ Fix a bunch of bugs that none of me noticed before. --- tools/maybe-mv | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'tools/maybe-mv') diff --git a/tools/maybe-mv b/tools/maybe-mv index 725b86b..996052f 100755 --- a/tools/maybe-mv +++ b/tools/maybe-mv @@ -1,8 +1,10 @@ #!/bin/bash -eu # Replace one file with another, but maybe don't update the timestamp -if cmp -s "$1" "$2" +if cmp "$1" "$2" then + echo rm "$1" rm "$1" else + echo mv "$1" "$2" mv "$1" "$2" fi -- cgit v1.2.3-60-g2f50