Thread (49 messages) flat view 49 messages, 1 author, 2016-06-15
DORMANTno replies

[PATCH v2 48/48] i18n: git-bisect bisect_next_check "You need to" message

From: Ævar Arnfjörð Bjarmason <hidden>
Date: 2016-06-15 22:51:17
Subsystem: the rest · Maintainer: Linus Torvalds

Gettextize the "You need to start by" message in
bisect_next_check. This message assembled English output by hand so it
needed to be split up to make it translatable.

Signed-off-by: Ævar Arnfjörð Bjarmason <redacted>
---
 git-bisect.sh |   25 ++++++++++++++++---------
 1 files changed, 16 insertions(+), 9 deletions(-)
diff --git a/git-bisect.sh b/git-bisect.sh
index 4416455..375b187 100755
--- a/git-bisect.sh
+++ b/git-bisect.sh
@@ -261,15 +261,22 @@ bisect_next_check() {
 		: bisect without good...
 		;;
 	*)
-		THEN=''
-		test -s "$GIT_DIR/BISECT_START" || {
-			echo >&2 'You need to start by "git bisect start".'
-			THEN='then '
-		}
-		echo >&2 'You '$THEN'need to give me at least one good' \
-			'and one bad revisions.'
-		echo >&2 '(You can use "git bisect bad" and' \
-			'"git bisect good" for that.)'
+
+		if test -s "$GIT_DIR/BISECT_START"
+		then
+			(
+				gettext "You need to give me at least one good and one bad revisions.
+(You can use \"git bisect bad\" and \"git bisect good\" for that.)" &&
+				echo
+			) >&2
+		else
+			(
+				gettext "You need to start by \"git bisect start\".
+You then need to give me at least one good and one bad revisions.
+(You can use \"git bisect bad\" and \"git bisect good\" for that.)" &&
+				echo
+			) >&2
+		fi
 		exit 1 ;;
 	esac
 }
-- 
1.7.5.1
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help