From: Ævar Arnfjörð Bjarmason Date: Mon, 13 Sep 2010 20:34:08 +0000 (+0000) Subject: gettextize: git-submodule $errmsg messages X-Git-Tag: ko-pu~10^2~26 X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=dec4ed9f564fd1dec21327a6f1b52048baf44bf5;p=git.git gettextize: git-submodule $errmsg messages 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 --- 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: