add logref support to git-symbolic-ref
Signed-off-by: Nicolas Pitre <nico@cam.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
This commit is contained in:
committed by
Junio C Hamano
parent
41b625b047
commit
8b5157e407
@ -381,7 +381,8 @@ static void rename_branch(const char *oldname, const char *newname, int force)
|
||||
if (rename_ref(oldref, newref, logmsg))
|
||||
die("Branch rename failed");
|
||||
|
||||
if (!strcmp(oldname, head) && create_symref("HEAD", newref))
|
||||
/* no need to pass logmsg here as HEAD didn't really move */
|
||||
if (!strcmp(oldname, head) && create_symref("HEAD", newref, NULL))
|
||||
die("Branch renamed to %s, but HEAD is not updated!", newname);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user