##// END OF EJS Templates
git: updated git patches
marcink -
r465:a16bf543 stable
parent child Browse files
Show More
@@ -1,94 +1,94 b''
1 --- a/git-sh-i18n.sh
1 --- a/git-sh-i18n.sh
2 +++ b/git-sh-i18n.sh
2 +++ b/git-sh-i18n.sh
3 @@ -15,87 +15,11 @@
3 @@ -15,87 +15,11 @@
4 fi
4 fi
5 export TEXTDOMAINDIR
5 export TEXTDOMAINDIR
6
6
7 -# First decide what scheme to use...
7 -# First decide what scheme to use...
8 -GIT_INTERNAL_GETTEXT_SH_SCHEME=fallthrough
8 -GIT_INTERNAL_GETTEXT_SH_SCHEME=fallthrough
9 -if test -n "@@USE_GETTEXT_SCHEME@@"
9 -if test -n "$GIT_GETTEXT_POISON"
10 -then
11 - GIT_INTERNAL_GETTEXT_SH_SCHEME=poison
12 -elif test -n "@@USE_GETTEXT_SCHEME@@"
10 -then
13 -then
11 - GIT_INTERNAL_GETTEXT_SH_SCHEME="@@USE_GETTEXT_SCHEME@@"
14 - GIT_INTERNAL_GETTEXT_SH_SCHEME="@@USE_GETTEXT_SCHEME@@"
12 -elif test -n "$GIT_INTERNAL_GETTEXT_TEST_FALLBACKS"
15 -elif test -n "$GIT_INTERNAL_GETTEXT_TEST_FALLBACKS"
13 -then
16 -then
14 - : no probing necessary
17 - : no probing necessary
15 -elif test -n "$GIT_GETTEXT_POISON"
16 -then
17 - GIT_INTERNAL_GETTEXT_SH_SCHEME=poison
18 -elif type gettext.sh >/dev/null 2>&1
18 -elif type gettext.sh >/dev/null 2>&1
19 -then
19 -then
20 - # GNU libintl's gettext.sh
20 - # GNU libintl's gettext.sh
21 - GIT_INTERNAL_GETTEXT_SH_SCHEME=gnu
21 - GIT_INTERNAL_GETTEXT_SH_SCHEME=gnu
22 -elif test "$(gettext -h 2>&1)" = "-h"
22 -elif test "$(gettext -h 2>&1)" = "-h"
23 -then
23 -then
24 - # gettext binary exists but no gettext.sh. likely to be a gettext
24 - # gettext binary exists but no gettext.sh. likely to be a gettext
25 - # binary on a Solaris or something that is not GNU libintl and
25 - # binary on a Solaris or something that is not GNU libintl and
26 - # lack eval_gettext.
26 - # lack eval_gettext.
27 - GIT_INTERNAL_GETTEXT_SH_SCHEME=gettext_without_eval_gettext
27 - GIT_INTERNAL_GETTEXT_SH_SCHEME=gettext_without_eval_gettext
28 -fi
28 -fi
29 -export GIT_INTERNAL_GETTEXT_SH_SCHEME
29 -export GIT_INTERNAL_GETTEXT_SH_SCHEME
30 -
30 -
31 -# ... and then follow that decision.
31 -# ... and then follow that decision.
32 -case "$GIT_INTERNAL_GETTEXT_SH_SCHEME" in
32 -case "$GIT_INTERNAL_GETTEXT_SH_SCHEME" in
33 -gnu)
33 -gnu)
34 - # Use libintl's gettext.sh, or fall back to English if we can't.
34 - # Use libintl's gettext.sh, or fall back to English if we can't.
35 - . gettext.sh
35 - . gettext.sh
36 - ;;
36 - ;;
37 -gettext_without_eval_gettext)
37 -gettext_without_eval_gettext)
38 - # Solaris has a gettext(1) but no eval_gettext(1)
38 - # Solaris has a gettext(1) but no eval_gettext(1)
39 - eval_gettext () {
39 - eval_gettext () {
40 - gettext "$1" | (
40 - gettext "$1" | (
41 - export PATH $(git sh-i18n--envsubst --variables "$1");
41 - export PATH $(git sh-i18n--envsubst --variables "$1");
42 - git sh-i18n--envsubst "$1"
42 - git sh-i18n--envsubst "$1"
43 - )
43 - )
44 - }
44 - }
45 -
45 -
46 - eval_ngettext () {
46 - eval_ngettext () {
47 - ngettext "$1" "$2" "$3" | (
47 - ngettext "$1" "$2" "$3" | (
48 - export PATH $(git sh-i18n--envsubst --variables "$2");
48 - export PATH $(git sh-i18n--envsubst --variables "$2");
49 - git sh-i18n--envsubst "$2"
49 - git sh-i18n--envsubst "$2"
50 - )
50 - )
51 - }
51 - }
52 - ;;
52 - ;;
53 -poison)
53 -poison)
54 - # Emit garbage so that tests that incorrectly rely on translatable
54 - # Emit garbage so that tests that incorrectly rely on translatable
55 - # strings will fail.
55 - # strings will fail.
56 - gettext () {
56 - gettext () {
57 - printf "%s" "# GETTEXT POISON #"
57 - printf "%s" "# GETTEXT POISON #"
58 - }
58 - }
59 -
59 -
60 - eval_gettext () {
60 - eval_gettext () {
61 - printf "%s" "# GETTEXT POISON #"
61 - printf "%s" "# GETTEXT POISON #"
62 - }
62 - }
63 -
63 -
64 - eval_ngettext () {
64 - eval_ngettext () {
65 - printf "%s" "# GETTEXT POISON #"
65 - printf "%s" "# GETTEXT POISON #"
66 - }
66 - }
67 - ;;
67 - ;;
68 -*)
68 -*)
69 - gettext () {
69 - gettext () {
70 - printf "%s" "$1"
70 - printf "%s" "$1"
71 - }
71 - }
72 -
72 -
73 - eval_gettext () {
73 - eval_gettext () {
74 - printf "%s" "$1" | (
74 - printf "%s" "$1" | (
75 - export PATH $(git sh-i18n--envsubst --variables "$1");
75 - export PATH $(git sh-i18n--envsubst --variables "$1");
76 - git sh-i18n--envsubst "$1"
76 - git sh-i18n--envsubst "$1"
77 - )
77 - )
78 - }
78 - }
79 +# GNU gettext
79 +# GNU gettext
80 +export GIT_INTERNAL_GETTEXT_SH_SCHEME=gnu
80 +export GIT_INTERNAL_GETTEXT_SH_SCHEME=gnu
81 +export PATH=@gettext@/bin:$PATH
81 +export PATH=@gettext@/bin:$PATH
82
82
83 - eval_ngettext () {
83 - eval_ngettext () {
84 - (test "$3" = 1 && printf "%s" "$1" || printf "%s" "$2") | (
84 - (test "$3" = 1 && printf "%s" "$1" || printf "%s" "$2") | (
85 - export PATH $(git sh-i18n--envsubst --variables "$2");
85 - export PATH $(git sh-i18n--envsubst --variables "$2");
86 - git sh-i18n--envsubst "$2"
86 - git sh-i18n--envsubst "$2"
87 - )
87 - )
88 - }
88 - }
89 - ;;
89 - ;;
90 -esac
90 -esac
91 +. @gettext@/bin/gettext.sh
91 +. @gettext@/bin/gettext.sh
92
92
93 # Git-specific wrapper functions
93 # Git-specific wrapper functions
94 gettextln () {
94 gettextln () {
@@ -1,26 +1,26 b''
1 diff --git a/connect.c b/connect.c
1 diff --git a/connect.c b/connect.c
2 index fd7ffe1..20cd992 100644
2 index c3a014c5b..fbca3262b 100644
3 --- a/connect.c
3 --- a/connect.c
4 +++ b/connect.c
4 +++ b/connect.c
5 @@ -768,7 +768,7 @@
5 @@ -1010,7 +1010,7 @@ static void fill_ssh_args(struct child_process *conn, const char *ssh_host,
6
6
7 ssh = getenv("GIT_SSH");
7 ssh = getenv("GIT_SSH");
8 if (!ssh)
8 if (!ssh)
9 - ssh = "ssh";
9 - ssh = "ssh";
10 + ssh = "@ssh@";
10 + ssh = "@ssh@";
11 else
11 variant = determine_ssh_variant(ssh, 0);
12 handle_ssh_variant(ssh, 0,
12 }
13 &port_option,
13
14 diff --git a/git-gui/lib/remote_add.tcl b/git-gui/lib/remote_add.tcl
14 diff --git a/git-gui/lib/remote_add.tcl b/git-gui/lib/remote_add.tcl
15 index 50029d0..17b9594 100644
15 index 480a6b30d..781720424 100644
16 --- a/git-gui/lib/remote_add.tcl
16 --- a/git-gui/lib/remote_add.tcl
17 +++ b/git-gui/lib/remote_add.tcl
17 +++ b/git-gui/lib/remote_add.tcl
18 @@ -139,7 +139,7 @@
18 @@ -139,7 +139,7 @@ method _add {} {
19 # Parse the location
19 # Parse the location
20 if { [regexp {(?:git\+)?ssh://([^/]+)(/.+)} $location xx host path]
20 if { [regexp {(?:git\+)?ssh://([^/]+)(/.+)} $location xx host path]
21 || [regexp {([^:][^:]+):(.+)} $location xx host path]} {
21 || [regexp {([^:][^:]+):(.+)} $location xx host path]} {
22 - set ssh ssh
22 - set ssh ssh
23 + set ssh @ssh@
23 + set ssh @ssh@
24 if {[info exists env(GIT_SSH)]} {
24 if {[info exists env(GIT_SSH)]} {
25 set ssh $env(GIT_SSH)
25 set ssh $env(GIT_SSH)
26 }
26 }
General Comments 0
You need to be logged in to leave comments. Login now