summaryrefslogtreecommitdiff
path: root/lib/branch_create.tcl
diff options
context:
space:
mode:
authorLibravatar Shawn O. Pearce <spearce@spearce.org>2007-07-05 19:19:37 -0400
committerLibravatar Shawn O. Pearce <spearce@spearce.org>2007-07-08 21:12:56 -0400
commit311e02a4a5c7b82c996214f06d58e2b51b3ecc22 (patch)
tree6036fbe6fc3fe2a621ba7d7cf235ab6d987947f6 /lib/branch_create.tcl
parentgit-gui: Automatically refresh tracking branches when needed (diff)
downloadtgif-311e02a4a5c7b82c996214f06d58e2b51b3ecc22.tar.xz
git-gui: Better handling of detached HEAD
If the current branch is not a symbolic-ref that points to a name in the refs/heads/ namespace we now just assume that the head is a detached head. In this case we return the special branch name of HEAD rather than empty string, as HEAD is a valid revision specification and the empty string is not. I have also slightly improved the current-branch function by using string functions to parse the symbolic-ref data. This should be slightly faster than using a regsub. I think the code is clearer too. Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
Diffstat (limited to 'lib/branch_create.tcl')
0 files changed, 0 insertions, 0 deletions