diff options
author | Nguyễn Thái Ngọc Duy <pclouds@gmail.com> | 2019-01-25 16:51:22 +0700 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2019-01-27 16:20:34 -0800 |
commit | dc40b24df47af35f486e2c5139121b6cddc2dcb9 (patch) | |
tree | cbd9cfb6e09f1888a23a89e0dd83e9bf8f4d27bf /mailmap.c | |
parent | Git 2.20.1 (diff) | |
download | tgif-dc40b24df47af35f486e2c5139121b6cddc2dcb9.tar.xz |
fetch: prefer suffix substitution in compact fetch.output
I have a remote named "jch" and it has a branch with the same name. And
fetch.output is set to "compact". Fetching this remote looks like this
From https://github.com/gitster/git
+ eb7fd39f6b...835363af2f jch -> */jch (forced update)
6f11fd5edb..59b12ae96a nd/config-move-to -> jch/*
* [new branch] nd/diff-parseopt -> jch/*
* [new branch] nd/the-index-final -> jch/*
Notice that the local side of branch jch starts with "*" instead of
ending with it like the rest. It's not exactly wrong. It just looks
weird.
This patch changes the find-and-replace code a bit to try finding prefix
first before falling back to strstr() which finds a substring from left
to right. Now we have something less OCD
From https://github.com/gitster/git
+ eb7fd39f6b...835363af2f jch -> jch/* (forced update)
6f11fd5edb..59b12ae96a nd/config-move-to -> jch/*
* [new branch] nd/diff-parseopt -> jch/*
* [new branch] nd/the-index-final -> jch/*
Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'mailmap.c')
0 files changed, 0 insertions, 0 deletions