[PATCH] guilt: fix date parsing
If the date field has a space in it, such as:
Date: Tue, 14 May 2013 18:37:15 +0200
previously guilt would go belly up:
+ export GIT_AUTHOR_DATE=Tue, 14 May 2013 18:37:15 +0200
/usr/local/bin/guilt: 571: export: 14: bad variable name
Fix this.
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
---
guilt | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/guilt b/guilt
index 9953bdf..6e8d542 100755
--- a/guilt
+++ b/guilt
@@ -568,7 +568,7 @@ commit()
author_date_str=`sed -n -e '/^Date:/ { s/^Date: //; p; q; }; /^(diff |---$|--- )/ q' "$p"`
fi
if [ ! -z "$author_date_str" ]; then
- export GIT_AUTHOR_DATE=`echo $author_date_str`
+ export GIT_AUTHOR_DATE="$author_date_str"
fi
fi
--
1.7.12.rc0.22.gcdd159b