aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorUlf Jasper2014-12-17 20:54:28 +0100
committerUlf Jasper2014-12-17 20:54:28 +0100
commitc17c864e7a71e267b7496afbe1d7076cca283cd7 (patch)
tree4aa3374301a7e09c6ca6d8e6909ad285092468e1
parent197a9e0c9e0c73ea5e76c10980e6265dd99439d9 (diff)
parent9be1538571e420b5a7bc7e93006cea1c1b47790e (diff)
downloademacs-c17c864e7a71e267b7496afbe1d7076cca283cd7.tar.gz
emacs-c17c864e7a71e267b7496afbe1d7076cca283cd7.zip
Merge branch 'master' of git.sv.gnu.org:/srv/git/emacs
-rw-r--r--lisp/net/tramp-sh.el17
1 files changed, 15 insertions, 2 deletions
diff --git a/lisp/net/tramp-sh.el b/lisp/net/tramp-sh.el
index c4d5e2fa97a..c639af3c230 100644
--- a/lisp/net/tramp-sh.el
+++ b/lisp/net/tramp-sh.el
@@ -65,6 +65,15 @@ files conditionalize this setup based on the TERM environment variable."
65 :type 'string) 65 :type 'string)
66 66
67;;;###tramp-autoload 67;;;###tramp-autoload
68(defcustom tramp-histfile-override "/dev/null"
69 "Whether the HISTFILE should be overridden to something. Set
70to nil to disable the override."
71 :group 'tramp
72 :type '(choice (const :tag "Do not override HISTFILE" nil)
73 (const :tag "Empty the history (/dev/null)" "/dev/null")
74 (string :tag "Redirect to a file")))
75
76;;;###tramp-autoload
68(defconst tramp-color-escape-sequence-regexp "\e[[;0-9]+m" 77(defconst tramp-color-escape-sequence-regexp "\e[[;0-9]+m"
69 "Escape sequences produced by the \"ls\" command.") 78 "Escape sequences produced by the \"ls\" command.")
70 79
@@ -3882,7 +3891,10 @@ file exists and nonzero exit status otherwise."
3882 ;; the prompt in /bin/bash, it must be discarded as well. 3891 ;; the prompt in /bin/bash, it must be discarded as well.
3883 (tramp-send-command 3892 (tramp-send-command
3884 vec (format 3893 vec (format
3885 "exec env ENV='' HISTFILE=/dev/null PROMPT_COMMAND='' PS1=%s PS2='' PS3='' %s %s" 3894 "exec env ENV=''%s PROMPT_COMMAND='' PS1=%s PS2='' PS3='' %s %s"
3895 (if tramp-histfile-override
3896 (concat " HISTFILE=" tramp-histfile-override)
3897 "")
3886 (tramp-shell-quote-argument tramp-end-of-output) 3898 (tramp-shell-quote-argument tramp-end-of-output)
3887 shell (or extra-args "")) 3899 shell (or extra-args ""))
3888 t)) 3900 t))
@@ -4603,7 +4615,8 @@ connection if a previous connection has died for some reason."
4603 (delete-process p)) 4615 (delete-process p))
4604 (setenv "TERM" tramp-terminal-type) 4616 (setenv "TERM" tramp-terminal-type)
4605 (setenv "LC_ALL" "en_US.utf8") 4617 (setenv "LC_ALL" "en_US.utf8")
4606 (setenv "HISTFILE" "/dev/null") 4618 (when tramp-histfile-override
4619 (setenv "HISTFILE" tramp-histfile-override))
4607 (setenv "PROMPT_COMMAND") 4620 (setenv "PROMPT_COMMAND")
4608 (setenv "PS1" tramp-initial-end-of-output) 4621 (setenv "PS1" tramp-initial-end-of-output)
4609 (let* ((target-alist (tramp-compute-multi-hops vec)) 4622 (let* ((target-alist (tramp-compute-multi-hops vec))