From 409fa556ce5c7e680d773d4bb01ca2c3162a9e9d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=86var=20Arnfj=C3=B6r=C3=B0=20Bjarmason?= Date: Tue, 22 Feb 2011 23:41:38 +0000 Subject: [PATCH] i18n: git-branch "(no branch)" message MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Gettextize the "(no branch)" message that's shown by "git branch" when you're in a detached HEAD. Signed-off-by: Ævar Arnfjörð Bjarmason Signed-off-by: Junio C Hamano --- builtin/branch.c | 2 +- t/t3203-branch-output.sh | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/builtin/branch.c b/builtin/branch.c index 4c1a256247..244589e736 100644 --- a/builtin/branch.c +++ b/builtin/branch.c @@ -476,7 +476,7 @@ static void show_detached(struct ref_list *ref_list) if (head_commit && is_descendant_of(head_commit, ref_list->with_commit)) { struct ref_item item; - item.name = xstrdup("(no branch)"); + item.name = xstrdup(_("(no branch)")); item.len = strlen(item.name); item.kind = REF_LOCAL_BRANCH; item.dest = NULL; diff --git a/t/t3203-branch-output.sh b/t/t3203-branch-output.sh index 6028748c6c..4ef7d09115 100755 --- a/t/t3203-branch-output.sh +++ b/t/t3203-branch-output.sh @@ -72,7 +72,7 @@ cat >expect <<'EOF' branch-two master EOF -test_expect_success 'git branch shows detached HEAD properly' ' +test_expect_success C_LOCALE_OUTPUT 'git branch shows detached HEAD properly' ' git checkout HEAD^0 && git branch >actual && test_cmp expect actual