summaryrefslogtreecommitdiff
path: root/git-am.sh
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2011-08-25 16:00:16 -0700
committerJunio C Hamano <gitster@pobox.com>2011-08-25 16:00:16 -0700
commit957450054cfbbe0d4ae8d33f7b74eace6e290f16 (patch)
tree65c27de698831bd6222152aa3dff0d7319628f27 /git-am.sh
parent1952e102b702b977d6bdfcee7cb48b843cb92049 (diff)
parent6ff875c52ae48b8fe6a350df110e33aa2ba8afbc (diff)
downloadgit-957450054cfbbe0d4ae8d33f7b74eace6e290f16.tar.gz
Merge branch 'js/i18n-scripts'
* js/i18n-scripts: submodule: take advantage of gettextln and eval_gettextln. stash: take advantage of eval_gettextln pull: take advantage of eval_gettextln git-am: take advantage of gettextln and eval_gettextln. gettext: add gettextln, eval_gettextln to encode common idiom
Diffstat (limited to 'git-am.sh')
-rwxr-xr-xgit-am.sh31
1 files changed, 14 insertions, 17 deletions
diff --git a/git-am.sh b/git-am.sh
index b2c4b2b853..e78cb547b7 100755
--- a/git-am.sh
+++ b/git-am.sh
@@ -90,11 +90,8 @@ safe_to_abort () {
then
return 0
fi
- (
- gettext "You seem to have moved HEAD since the last 'am' failure.
-Not rewinding to ORIG_HEAD" &&
- echo
- ) >&2
+ gettextln "You seem to have moved HEAD since the last 'am' failure.
+Not rewinding to ORIG_HEAD" >&2
return 1
}
@@ -103,9 +100,9 @@ stop_here_user_resolve () {
printf '%s\n' "$resolvemsg"
stop_here $1
fi
- eval_gettext "When you have resolved this problem run \"\$cmdline --resolved\".
+ eval_gettextln "When you have resolved this problem run \"\$cmdline --resolved\".
If you would prefer to skip this patch, instead run \"\$cmdline --skip\".
-To restore the original branch and stop patching run \"\$cmdline --abort\"."; echo
+To restore the original branch and stop patching run \"\$cmdline --abort\"."
stop_here $1
}
@@ -119,7 +116,7 @@ go_next () {
cannot_fallback () {
echo "$1"
- gettext "Cannot fall back to three-way merge."; echo
+ gettextln "Cannot fall back to three-way merge."
exit 1
}
@@ -619,9 +616,9 @@ do
go_next && continue
test -s "$dotest/patch" || {
- eval_gettext "Patch is empty. Was it split wrong?
+ eval_gettextln "Patch is empty. Was it split wrong?
If you would prefer to skip this patch, instead run \"\$cmdline --skip\".
-To restore the original branch and stop patching run \"\$cmdline --abort\"."; echo
+To restore the original branch and stop patching run \"\$cmdline --abort\"."
stop_here $this
}
rm -f "$dotest/original-commit" "$dotest/author-script"
@@ -656,7 +653,7 @@ To restore the original branch and stop patching run \"\$cmdline --abort\"."; ec
if test -z "$GIT_AUTHOR_EMAIL"
then
- gettext "Patch does not have a valid e-mail address."; echo
+ gettextln "Patch does not have a valid e-mail address."
stop_here $this
fi
@@ -707,7 +704,7 @@ To restore the original branch and stop patching run \"\$cmdline --abort\"."; ec
action=again
while test "$action" = again
do
- gettext "Commit Body is:"; echo
+ gettextln "Commit Body is:"
echo "--------------------------"
cat "$dotest/final-commit"
echo "--------------------------"
@@ -771,16 +768,16 @@ To restore the original branch and stop patching run \"\$cmdline --abort\"."; ec
# working tree.
resolved=
git diff-index --quiet --cached HEAD -- && {
- gettext "No changes - did you forget to use 'git add'?
+ gettextln "No changes - did you forget to use 'git add'?
If there is nothing left to stage, chances are that something else
-already introduced the same changes; you might want to skip this patch."; echo
+already introduced the same changes; you might want to skip this patch."
stop_here_user_resolve $this
}
unmerged=$(git ls-files -u)
if test -n "$unmerged"
then
- gettext "You still have unmerged paths in your index
-did you forget to use 'git add'?"; echo
+ gettextln "You still have unmerged paths in your index
+did you forget to use 'git add'?"
stop_here_user_resolve $this
fi
apply_status=0
@@ -805,7 +802,7 @@ did you forget to use 'git add'?"; echo
fi
if test $apply_status != 0
then
- eval_gettext 'Patch failed at $msgnum $FIRSTLINE'; echo
+ eval_gettextln 'Patch failed at $msgnum $FIRSTLINE'
stop_here_user_resolve $this
fi