emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] master 98586c2 2/2: Merge branch 'master' of git.savannah.


From: Eli Zaretskii
Subject: [Emacs-diffs] master 98586c2 2/2: Merge branch 'master' of git.savannah.gnu.org:/srv/git/emacs
Date: Wed, 18 Sep 2019 08:15:37 -0400 (EDT)

branch: master
commit 98586c2fe62fd26bc9105a06b78d93446bd2a269
Merge: 7ff2eef ffcec7c
Author: Eli Zaretskii <address@hidden>
Commit: Eli Zaretskii <address@hidden>

    Merge branch 'master' of git.savannah.gnu.org:/srv/git/emacs
---
 doc/misc/tramp.texi          | 29 +++++++++++++++++++++++++++++
 lisp/net/tramp-sh.el         |  4 +++-
 test/lisp/net/tramp-tests.el |  7 ++-----
 3 files changed, 34 insertions(+), 6 deletions(-)

diff --git a/doc/misc/tramp.texi b/doc/misc/tramp.texi
index e6a454b..1ed334b 100644
--- a/doc/misc/tramp.texi
+++ b/doc/misc/tramp.texi
@@ -1591,6 +1591,7 @@ via the @command{CONNECT} command (conforming to RFC 
2616, 2817
 specifications).  Proxy servers using HTTP 1.1 or later protocol
 support this command.
 
+
 @subsection Tunneling with ssh
 
 With ssh, you could use the @code{ProxyCommand} entry in
@@ -1609,6 +1610,7 @@ Any other program with such a feature could be used as 
well.
 In the example, opening @file{@trampfn{ssh,host.your.domain,}} passes
 the HTTP proxy server @samp{proxy.your.domain} on port 3128.
 
+
 @subsection Tunneling with PuTTY
 
 PuTTY does not need an external program, HTTP tunnel support is
@@ -2092,6 +2094,33 @@ be recomputed.  To force @value{tramp} to recompute 
afresh, call
 
 @node Remote shell setup
 @section Remote shell setup hints
+
+
+@subsection Changing the default remote shell
+@cindex zsh setup
+
+Per default, @value{tramp} uses the command @command{/bin/sh} for
+strting a shell on the remote host.  This can be changed by setting
+the connection property @option{remote-shell}, see @xref{Predefined
+connection information}.  Other properties might be adapted as well,
+like @option{remote-shell-login} or @option{remote-shell-args}.  If
+you want, for example, use @command{/usr/bin/zsh} on a remote host,
+you might apply
+
+@lisp
+@group
+(add-to-list 'tramp-connection-properties
+             (list (regexp-quote "@trampfn{ssh,user@@host,}")
+                   "remote-shell" "/usr/bin/zsh"))
+@end group
+@end lisp
+
+This approach has also the advantage, that settings in
+@code{tramp-sh-extra-args} will be applied.  For zsh, the trouble
+with the shell prompt due to set zle options will be avoided.
+
+
+@subsection Other remote shell setup hints
 @cindex remote shell setup
 @cindex @file{.profile} file
 @cindex @file{.login} file
diff --git a/lisp/net/tramp-sh.el b/lisp/net/tramp-sh.el
index 4bc37f0..8092f6a 100644
--- a/lisp/net/tramp-sh.el
+++ b/lisp/net/tramp-sh.el
@@ -525,7 +525,9 @@ based on the Tramp and Emacs versions, and should not be 
set here."
   :type '(repeat string))
 
 ;;;###tramp-autoload
-(defcustom tramp-sh-extra-args '(("/bash\\'" . "-norc -noprofile"))
+(defcustom tramp-sh-extra-args
+  '(("/bash\\'" . "-norc -noprofile")
+    ("/zsh\\'" . "-f +Z"))
   "Alist specifying extra arguments to pass to the remote shell.
 Entries are (REGEXP . ARGS) where REGEXP is a regular expression
 matching the shell file name and ARGS is a string specifying the
diff --git a/test/lisp/net/tramp-tests.el b/test/lisp/net/tramp-tests.el
index 1554d3b..d7e0a04 100644
--- a/test/lisp/net/tramp-tests.el
+++ b/test/lisp/net/tramp-tests.el
@@ -2412,9 +2412,7 @@ This checks also `file-name-as-directory', 
`file-name-directory',
          (unwind-protect
              ;; FIXME: This fails on my QNAP server, see
              ;; /share/Web/owncloud/data/owncloud.log
-             (unless (and (tramp--test-nextcloud-p)
-                          (or (not (file-remote-p source))
-                              (not (file-remote-p target))))
+             (unless (tramp--test-nextcloud-p)
                (make-directory source)
                (should (file-directory-p source))
                (write-region "foo" nil (expand-file-name "foo" source))
@@ -2437,8 +2435,7 @@ This checks also `file-name-as-directory', 
`file-name-directory',
          (unwind-protect
              ;; FIXME: This fails on my QNAP server, see
              ;; /share/Web/owncloud/data/owncloud.log
-             (unless
-                 (and (tramp--test-nextcloud-p) (not (file-remote-p source)))
+             (unless (tramp--test-nextcloud-p)
                (make-directory source)
                (should (file-directory-p source))
                (write-region "foo" nil (expand-file-name "foo" source))



reply via email to

[Prev in Thread] Current Thread [Next in Thread]