summaryrefslogtreecommitdiffstats
path: root/bin/fetchgit
diff options
context:
space:
mode:
authortv <tv@shackspace.de>2015-06-28 14:45:23 +0200
committertv <tv@shackspace.de>2015-06-28 14:45:23 +0200
commitf44736bb6c2f6051141bafd7fd88bdea08a02790 (patch)
treec829324cf7f3239ae8c6b08070da6c5a3036b2f6 /bin/fetchgit
parent55d4b488033549773353761898fc00879f21d612 (diff)
fetchgit: is_up_to_date requires rev to be a sha1
Diffstat (limited to 'bin/fetchgit')
-rwxr-xr-xbin/fetchgit3
1 files changed, 2 insertions, 1 deletions
diff --git a/bin/fetchgit b/bin/fetchgit
index 09cc0e202..ffd7e7426 100755
--- a/bin/fetchgit
+++ b/bin/fetchgit
@@ -35,7 +35,8 @@ work_git() {
is_up_to_date() {
test -d "$cache_dir" &&
test -d "$work_dir" &&
- test "$(work_git rev-parse HEAD)" = "$(cache_git rev-parse "$git_rev")"
+ test "$(cache_git rev-parse "$git_rev")" = "$git_rev" &&
+ test "$(work_git rev-parse HEAD)" = "$git_rev"
}
# Notice how the remote name "origin" has been chosen arbitrarily.