completion: fix completing merge strategies on non-C locales

The anchor string "Available strategies are:" is translatable so __git_list_merge_strategies may fail to collect available strategies from 'git merge' on non-C locales. Force C locale on this command. Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>

Duy Nguyen committed Jan 26, 2018 at 08:31 UTC 7cc763aaa3f39c62e0b2d5520e9d2bd8e4f3c4b3
1 file changed +1 -1
contrib/completion/git-completion.bash
+1 -1
@@ -594,7 +594,7 @@ __git_is_configured_remote ()
594
595 __git_list_merge_strategies ()
596 {
597 - git merge -s help 2>&1 |
597 + LANG=C LC_ALL=C git merge -s help 2>&1 |
598 sed -n -e '/[Aa]vailable strategies are: /,/^$/{
599 s/\.$//
600 s/.*://