Skip to content

Commit

Permalink
Merge branch 'fixes'
Browse files Browse the repository at this point in the history
  • Loading branch information
Junio C Hamano committed Sep 25, 2005
2 parents 00d8bbd + fbaf834 commit cfd8aef
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 2 deletions.
2 changes: 1 addition & 1 deletion git-grep.sh
Original file line number Diff line number Diff line change
Expand Up @@ -40,4 +40,4 @@ while : ; do
shift
done
git-ls-files -z "${git_flags[@]}" "$@" |
xargs -0 grep "${flags[@]}" "$pattern"
xargs -0 grep "${flags[@]}" -e "$pattern"
15 changes: 14 additions & 1 deletion show-branch.c
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,20 @@ static void name_commits(struct commit_list *list,
nth++;
if (p->object.util)
continue;
sprintf(newname, "%s^%d", n->head_name, nth);
switch (n->generation) {
case 0:
sprintf(newname, "%s^%d",
n->head_name, nth);
break;
case 1:
sprintf(newname, "%s^^%d",
n->head_name, nth);
break;
default:
sprintf(newname, "%s~%d^%d",
n->head_name, n->generation,
nth);
}
name_commit(p, strdup(newname), 0);
i++;
name_first_parent_chain(p);
Expand Down

0 comments on commit cfd8aef

Please sign in to comment.