From dec4ed9f564fd1dec21327a6f1b52048baf44bf5 Mon Sep 17 00:00:00 2001 From: =?utf8?q?=C3=86var=20Arnfj=C3=B6r=C3=B0=20Bjarmason?= Date: Mon, 13 Sep 2010 20:34:08 +0000 Subject: [PATCH] gettextize: git-submodule $errmsg messages MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Gettextize warning messages stored in the $errmsg variable using eval_gettext interpolation. This is explicitly tested for so we need to skip some tests with NO_GETTEXT_POISON. Signed-off-by: Ævar Arnfjörð Bjarmason --- git-submodule.sh | 6 +++--- t/t7401-submodule-summary.sh | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/git-submodule.sh b/git-submodule.sh index 065b3434a..d453fe96c 100755 --- a/git-submodule.sh +++ b/git-submodule.sh @@ -643,13 +643,13 @@ cmd_summary() { total_commits= case "$missing_src,$missing_dst" in t,) - errmsg=" Warn: $name doesn't contain commit $sha1_src" + errmsg="$(eval_gettext " Warn: \$name doesn't contain commit \$sha1_src")" ;; ,t) - errmsg=" Warn: $name doesn't contain commit $sha1_dst" + errmsg="$(eval_gettext " Warn: \$name doesn't contain commit \$sha1_dst")" ;; t,t) - errmsg=" Warn: $name doesn't contain commits $sha1_src and $sha1_dst" + errmsg="$(eval_gettext " Warn: \$name doesn't contain commits \$sha1_src and \$sha1_dst")" ;; *) errmsg= diff --git a/t/t7401-submodule-summary.sh b/t/t7401-submodule-summary.sh index e14a2de0d..f33f071a3 100755 --- a/t/t7401-submodule-summary.sh +++ b/t/t7401-submodule-summary.sh @@ -155,7 +155,7 @@ EOF rm -f sm1 && test_create_repo sm1 && head6=$(add_file sm1 foo6 foo7) -test_expect_success 'nonexistent commit' " +test_expect_success NO_GETTEXT_POISON 'nonexistent commit' " git submodule summary >actual && cat >expected <<-EOF && * sm1 $head4...$head6: -- 2.30.2