From cdccd89df4dedbe8466f1e16b248a8a0f43b45db Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20Mart=C3=AD?= Date: Tue, 5 Nov 2013 00:11:54 +0100 Subject: [PATCH] Solve issues with fd-commit when no Auto Name is present --- fd-commit | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/fd-commit b/fd-commit index 9f1a5a21..e833e034 100755 --- a/fd-commit +++ b/fd-commit @@ -23,6 +23,7 @@ while read line; do [ -d metadata/$id ] && extra=metadata/$id + name= while read l; do if [[ "$l" == "Auto Name:"* ]]; then name=${l##*:} @@ -30,7 +31,7 @@ while read line; do fi done < "$file" - [ -n "$name" ] && id="$name ($id)" + [ -n "$name" ] && fullname="$name ($id)" || fullname=$id newbuild=0 while read l; do @@ -44,9 +45,9 @@ while read line; do done < <(git diff HEAD -- "$file") if [ $newbuild -eq 0 ]; then - message="$id:" + message="$fullname:" else - message="Update $id to $version ($vercode)" + message="Update $fullname to $version ($vercode)" fi commands+=("git commit -m '$message' -e -v -- $file $extra")