From: Michael Albinus <michael.albinus@gmx.de>
To: "Ævar Arnfjörð Bjarmason" <avarab@gmail.com>
Cc: 24478@debbugs.gnu.org, Ted Zlatanov <tzz@lifelogs.com>
Subject: bug#24478: 25.1; Regression in 25.1: .tramp_history files are littered in non-$HOME working directories
Date: Sat, 15 Oct 2016 12:38:15 +0200 [thread overview]
Message-ID: <871szhsxrc.fsf@gmx.de> (raw)
In-Reply-To: <8760owky8n.fsf@gmx.de> (Michael Albinus's message of "Thu, 13 Oct 2016 18:30:32 +0200")
Michael Albinus <michael.albinus@gmx.de> writes:
Hi Ævar,
>> I.e. their /bin/sh is always bash, as opposed to say the more minimal
>> dash shell on Debian.
>
> Indeed. All the bugs I've quoted were related to bash.
Well, I've partly reverted the fix for bug#20446. This shall fix the
problem for you. See appended patch.
Glenn, you have reported bug#20446. I believe that I haven't
reintroduced your problem, but I would appreciate pretty much if you
could cross-check this. The point is NOT to set $HISTFILESIZE.
Best regards, Michael.
--8<---------------cut here---------------start------------->8---
*** /home/albinus/src/emacs-25/lisp/net/tramp-sh.el.~4f406e9813e073b675bb45613bf1dd111eec2368~ 2016-10-15 12:34:57.847998549 +0200
--- /home/albinus/src/emacs-25/lisp/net/tramp-sh.el 2016-10-15 12:28:04.562663524 +0200
***************
*** 67,85 ****
:type 'string)
;;;###tramp-autoload
! (defcustom tramp-histfile-override ".tramp_history"
"When invoking a shell, override the HISTFILE with this value.
When setting to a string, it redirects the shell history to that
file. Be careful when setting to \"/dev/null\"; this might
result in undesired results when using \"bash\" as shell.
The value t, the default value, unsets any setting of HISTFILE,
! and sets both HISTFILESIZE and HISTSIZE to 0. If you set this
! variable to nil, however, the *override* is disabled, so the
! history will go to the default storage location,
! e.g. \"$HOME/.sh_history\"."
:group 'tramp
! :version "25.1"
:type '(choice (const :tag "Do not override HISTFILE" nil)
(const :tag "Unset HISTFILE" t)
(string :tag "Redirect to a file")))
--- 67,84 ----
:type 'string)
;;;###tramp-autoload
! (defcustom tramp-histfile-override t
"When invoking a shell, override the HISTFILE with this value.
When setting to a string, it redirects the shell history to that
file. Be careful when setting to \"/dev/null\"; this might
result in undesired results when using \"bash\" as shell.
The value t, the default value, unsets any setting of HISTFILE,
! and sets HISTSIZE to 0. If you set this variable to nil,
! however, the *override* is disabled, so the history will go to
! the default storage location, e.g. \"$HOME/.sh_history\"."
:group 'tramp
! :version "25.2"
:type '(choice (const :tag "Do not override HISTFILE" nil)
(const :tag "Unset HISTFILE" t)
(string :tag "Redirect to a file")))
***************
*** 4113,4119 ****
(format "HISTFILE=%s"
(tramp-shell-quote-argument tramp-histfile-override))
(if tramp-histfile-override
! "HISTFILE='' HISTFILESIZE=0 HISTSIZE=0"
""))
(tramp-shell-quote-argument tramp-end-of-output)
shell (or extra-args ""))
--- 4112,4118 ----
(format "HISTFILE=%s"
(tramp-shell-quote-argument tramp-histfile-override))
(if tramp-histfile-override
! "HISTFILE='' HISTSIZE=0"
""))
(tramp-shell-quote-argument tramp-end-of-output)
shell (or extra-args ""))
***************
*** 4885,4891 ****
(if tramp-histfile-override
(progn
(setenv "HISTFILE")
- (setenv "HISTFILESIZE" "0")
(setenv "HISTSIZE" "0"))))
(setenv "PROMPT_COMMAND")
(setenv "PS1" tramp-initial-end-of-output)
--- 4884,4889 ----
--8<---------------cut here---------------end--------------->8---
next prev parent reply other threads:[~2016-10-15 10:38 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-09-20 10:21 bug#24478: 25.1; Regression in 25.1: .tramp_history files are littered in non-$HOME working directories Ævar Arnfjörð Bjarmason
2016-09-22 18:02 ` Michael Albinus
2016-10-10 10:38 ` Eli Zaretskii
2016-10-10 11:14 ` Ævar Arnfjörð Bjarmason
2016-10-11 13:54 ` Michael Albinus
2016-10-11 14:34 ` Ævar Arnfjörð Bjarmason
2016-10-11 14:44 ` Michael Albinus
2016-10-11 14:47 ` Ævar Arnfjörð Bjarmason
2016-10-12 14:05 ` Michael Albinus
2016-10-13 14:51 ` Michael Albinus
2016-10-13 15:18 ` Ævar Arnfjörð Bjarmason
2016-10-13 16:30 ` Michael Albinus
2016-10-15 10:38 ` Michael Albinus [this message]
2016-10-22 16:55 ` Michael Albinus
2016-10-23 23:29 ` Glenn Morris
2016-10-24 7:09 ` Michael Albinus
2016-10-24 13:10 ` Michael Albinus
2016-10-24 13:54 ` Ævar Arnfjörð Bjarmason
2016-10-24 14:32 ` Michael Albinus
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=871szhsxrc.fsf@gmx.de \
--to=michael.albinus@gmx.de \
--cc=24478@debbugs.gnu.org \
--cc=avarab@gmail.com \
--cc=tzz@lifelogs.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).