提交 6718f1f0 编写于 作者: J Johannes Sixt 提交者: Junio C Hamano

git-remote show: Also shorten non-fast-forward refs in the 'push' listing

'git-remote show remote-name' lists the refs that are pushed to the remote
by showing the 'Push' line from the config file. But before showing it,
it shortened 'refs/heads/here:refs/heads/there' to 'here:there'. However,
if the Push line is prefixed with a plus, the ref was not shortened.
Signed-off-by: NJohannes Sixt <johannes.sixt@telecom.at>
Signed-off-by: NJunio C Hamano <gitster@pobox.com>
上级 9a7d9410
......@@ -258,6 +258,7 @@ sub show_remote {
if ($info->{'PUSH'}) {
my @pushed = map {
s|^refs/heads/||;
s|^\+refs/heads/|+|;
s|:refs/heads/|:|;
$_;
} @{$info->{'PUSH'}};
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册