From: "Ævar Arnfjörð Bjarmason" <avarab@gmail.com>
To: git@vger.kernel.org
Cc: "Junio C Hamano" <gitster@pobox.com>,
"Ævar Arnfjörð Bjarmason" <avarab@gmail.com>
Subject: [PATCH 11/48] i18n: git-am core say messages
Date: Sun, 8 May 2011 12:20:43 +0000 [thread overview]
Message-ID: <1304857280-14773-12-git-send-email-avarab@gmail.com> (raw)
In-Reply-To: <1304857280-14773-1-git-send-email-avarab@gmail.com>
Make the core git-am messages that use say() translatable. These are
visible on almost every git am invocation.
There are tests that depend on the "Applying" output that need to be
changed to use the test_i18* functions along with this translation.
Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com>
---
git-am.sh | 6 +++---
t/t4150-am.sh | 2 +-
t/t4151-am-abort.sh | 5 +++--
3 files changed, 7 insertions(+), 6 deletions(-)
diff --git a/git-am.sh b/git-am.sh
index 903d1e3..77ecae7 100755
--- a/git-am.sh
+++ b/git-am.sh
@@ -739,7 +739,7 @@ To restore the original branch and stop patching run \"\$cmdline --abort\"."; ec
stop_here $this
fi
- say "Applying: $FIRSTLINE"
+ say "$(eval_gettext "Applying: \$FIRSTLINE")"
case "$resolved" in
'')
@@ -784,7 +784,7 @@ did you forget to use 'git add'?"; echo
# Applying the patch to an earlier tree and merging the
# result may have produced the same tree as ours.
git diff-index --quiet --cached HEAD -- && {
- say No changes -- Patch already applied.
+ say "$(gettext "No changes -- Patch already applied.")"
go_next
continue
}
@@ -810,7 +810,7 @@ did you forget to use 'git add'?"; echo
GIT_AUTHOR_DATE=
fi
parent=$(git rev-parse --verify -q HEAD) ||
- say >&2 "applying to an empty history"
+ say >&2 "$(gettext "applying to an empty history")"
if test -n "$committer_date_is_author_date"
then
diff --git a/t/t4150-am.sh b/t/t4150-am.sh
index 850fc96..151404e 100755
--- a/t/t4150-am.sh
+++ b/t/t4150-am.sh
@@ -465,7 +465,7 @@ test_expect_success 'am newline in subject' '
test_tick &&
sed -e "s/second/second \\\n foo/" patch1 >patchnl &&
git am <patchnl >output.out 2>&1 &&
- grep "^Applying: second \\\n foo$" output.out
+ test_i18ngrep "^Applying: second \\\n foo$" output.out
'
test_expect_success 'am -q is quiet' '
diff --git a/t/t4151-am-abort.sh b/t/t4151-am-abort.sh
index c95c4cc..1176bcc 100755
--- a/t/t4151-am-abort.sh
+++ b/t/t4151-am-abort.sh
@@ -45,8 +45,9 @@ do
test_expect_success "am$with3 --skip continue after failed am$with3" '
test_must_fail git am$with3 --skip >output &&
- test "$(grep "^Applying" output)" = "Applying: 6" &&
- test_cmp file-2-expect file-2 &&
+ test_i18ngrep "^Applying" output >output.applying &&
+ test_i18ngrep "^Applying: 6$" output.applying &&
+ test_i18ncmp file-2-expect file-2 &&
test ! -f .git/MERGE_RR
'
--
1.7.4.4
next prev parent reply other threads:[~2011-05-08 12:23 UTC|newest]
Thread overview: 59+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-05-08 12:20 [PATCH 00/48] i18n: Add shell script translations (depends on infrastructure) Ævar Arnfjörð Bjarmason
2011-05-08 12:20 ` [PATCH 01/48] i18n: git-am add git-sh-i18n Ævar Arnfjörð Bjarmason
2011-05-08 12:20 ` [PATCH 02/48] i18n: git-am one-line gettext $msg; echo Ævar Arnfjörð Bjarmason
2011-05-08 12:20 ` [PATCH 03/48] i18n: git-am multi-line getttext " Ævar Arnfjörð Bjarmason
2011-05-08 12:20 ` [PATCH 04/48] i18n: git-am eval_gettext messages Ævar Arnfjörð Bjarmason
2011-05-08 12:20 ` [PATCH 05/48] i18n: git-am echo + gettext message Ævar Arnfjörð Bjarmason
2011-05-08 12:20 ` [PATCH 06/48] i18n: git-am die messages Ævar Arnfjörð Bjarmason
2011-05-08 12:20 ` [PATCH 07/48] i18n: git-am cannot_fallback messages Ævar Arnfjörð Bjarmason
2011-05-08 12:20 ` [PATCH 08/48] i18n: git-am clean_abort messages Ævar Arnfjörð Bjarmason
2011-05-08 12:20 ` [PATCH 09/48] i18n: git-am "Apply?" message Ævar Arnfjörð Bjarmason
2011-05-08 12:20 ` [PATCH 10/48] i18n: git-am "Falling back" say message Ævar Arnfjörð Bjarmason
2011-05-08 12:20 ` Ævar Arnfjörð Bjarmason [this message]
2011-05-08 12:20 ` [PATCH 12/48] i18n: git-am printf(1) message to eval_gettext Ævar Arnfjörð Bjarmason
2011-05-08 12:20 ` [PATCH 13/48] i18n: git-pull add git-sh-i18n Ævar Arnfjörð Bjarmason
2011-05-08 12:20 ` [PATCH 14/48] i18n: git-pull die messages Ævar Arnfjörð Bjarmason
2011-05-08 12:20 ` [PATCH 15/48] i18n: git-pull eval_gettext + die message Ævar Arnfjörð Bjarmason
2011-05-08 12:20 ` [PATCH 16/48] i18n: git-pull eval_gettext + warning message Ævar Arnfjörð Bjarmason
2011-05-08 16:52 ` Bernhard R. Link
2011-05-08 20:19 ` Junio C Hamano
2011-05-08 12:20 ` [PATCH 17/48] i18n: git-submodule add git-sh-i18n Ævar Arnfjörð Bjarmason
2011-05-08 12:20 ` [PATCH 18/48] i18n: git-submodule echo + eval_gettext messages Ævar Arnfjörð Bjarmason
2011-05-08 12:20 ` [PATCH 19/48] i18n: git-submodule say " Ævar Arnfjörð Bjarmason
2011-05-08 12:20 ` [PATCH 20/48] i18n: git-submodule die " Ævar Arnfjörð Bjarmason
2011-05-12 8:08 ` Johannes Sixt
2011-05-12 13:48 ` Ævar Arnfjörð Bjarmason
2011-05-12 14:20 ` Johannes Sixt
2011-05-13 8:21 ` Ævar Arnfjörð Bjarmason
2011-05-13 9:04 ` Erik Faye-Lund
2011-05-13 9:48 ` Ævar Arnfjörð Bjarmason
2011-05-08 12:20 ` [PATCH 21/48] i18n: git-submodule $update_module say + die messages Ævar Arnfjörð Bjarmason
2011-05-08 12:20 ` [PATCH 22/48] i18n: git-submodule "cached cannot be used" message Ævar Arnfjörð Bjarmason
2011-05-08 12:20 ` [PATCH 23/48] i18n: git-submodule "Submodule change[...]" messages Ævar Arnfjörð Bjarmason
2011-05-08 12:20 ` [PATCH 24/48] i18n: git-submodule $errmsg messages Ævar Arnfjörð Bjarmason
2011-05-08 12:20 ` [PATCH 25/48] i18n: git-submodule "Entering [...]" message Ævar Arnfjörð Bjarmason
2011-05-08 12:20 ` [PATCH 26/48] i18n: git-submodule "[...] path is ignored" message Ævar Arnfjörð Bjarmason
2011-05-08 12:20 ` [PATCH 27/48] i18n: git-submodule "path not initialized" message Ævar Arnfjörð Bjarmason
2011-05-08 12:21 ` [PATCH 28/48] i18n: git-submodule "blob" and "submodule" messages Ævar Arnfjörð Bjarmason
2011-05-08 12:21 ` [PATCH 29/48] i18n: git-stash add git-sh-i18n Ævar Arnfjörð Bjarmason
2011-05-08 12:21 ` [PATCH 30/48] i18n: git-stash echo + gettext message Ævar Arnfjörð Bjarmason
2011-05-08 12:21 ` [PATCH 31/48] i18n: git-stash say + gettext messages Ævar Arnfjörð Bjarmason
2011-05-08 12:21 ` [PATCH 32/48] i18n: git-stash die " Ævar Arnfjörð Bjarmason
2011-05-08 12:21 ` [PATCH 33/48] i18n: git-stash die + eval_gettext messages Ævar Arnfjörð Bjarmason
2011-05-08 12:21 ` [PATCH 34/48] i18n: git-stash die + eval_gettext $* messages Ævar Arnfjörð Bjarmason
2011-05-08 12:21 ` [PATCH 35/48] i18n: git-stash die + eval_gettext $1 messages Ævar Arnfjörð Bjarmason
2011-05-08 12:21 ` [PATCH 36/48] i18n: git-stash "unknown option" message Ævar Arnfjörð Bjarmason
2011-05-08 15:29 ` Motiejus Jakštys
2011-05-08 21:38 ` Ævar Arnfjörð Bjarmason
2011-05-08 12:21 ` [PATCH 37/48] i18n: git-stash drop_stash say/die messages Ævar Arnfjörð Bjarmason
2011-05-08 12:21 ` [PATCH 38/48] i18n: git-bisect add git-sh-i18n Ævar Arnfjörð Bjarmason
2011-05-08 12:21 ` [PATCH 39/48] i18n: git-bisect gettext + echo message Ævar Arnfjörð Bjarmason
2011-05-08 12:21 ` [PATCH 40/48] i18n: git-bisect echo + gettext messages Ævar Arnfjörð Bjarmason
2011-05-08 12:21 ` [PATCH 41/48] i18n: git-bisect echo + eval_gettext message Ævar Arnfjörð Bjarmason
2011-05-08 12:21 ` [PATCH 42/48] i18n: git-bisect die + gettext messages Ævar Arnfjörð Bjarmason
2011-05-08 12:21 ` [PATCH 43/48] i18n: git-bisect die + eval_gettext messages Ævar Arnfjörð Bjarmason
2011-05-08 12:21 ` [PATCH 44/48] i18n: git-bisect bisect_run + $@ messages Ævar Arnfjörð Bjarmason
2011-05-08 12:21 ` [PATCH 45/48] i18n: git-bisect bisect_reset + $1 messages Ævar Arnfjörð Bjarmason
2011-05-08 12:21 ` [PATCH 46/48] i18n: git-bisect bisect_replay " Ævar Arnfjörð Bjarmason
2011-05-08 12:21 ` [PATCH 47/48] i18n: git-bisect [Y/n] messages Ævar Arnfjörð Bjarmason
2011-05-08 12:21 ` [PATCH 48/48] i18n: git-bisect bisect_next_check "You need to" message Ævar Arnfjörð Bjarmason
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1304857280-14773-12-git-send-email-avarab@gmail.com \
--to=avarab@gmail.com \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).