emacs-bug-tracker
[Top][All Lists]
Advanced

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

bug#51426: closed (29.0.50; [PATCH] Should 'comint-term-environment' be


From: GNU bug Tracking System
Subject: bug#51426: closed (29.0.50; [PATCH] Should 'comint-term-environment' be connection-aware?)
Date: Thu, 28 Oct 2021 16:50:02 +0000

Your message dated Thu, 28 Oct 2021 18:48:58 +0200
with message-id <878rydxfgl.fsf@gmx.de>
and subject line Re: bug#51426: 29.0.50; [PATCH] Should 
'comint-term-environment' be connection-aware?
has caused the debbugs.gnu.org bug report #51426,
regarding 29.0.50; [PATCH] Should 'comint-term-environment' be connection-aware?
to be marked as done.

(If you believe you have received this mail in error, please contact
help-debbugs@gnu.org.)


-- 
51426: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=51426
GNU Bug Tracking System
Contact help-debbugs@gnu.org with problems
--- Begin Message --- Subject: 29.0.50; [PATCH] Should 'comint-term-environment' be connection-aware? Date: Tue, 26 Oct 2021 15:54:03 -0700 `comint-term-environment' consults `system-uses-terminfo' to determine how to set environment variables to indicate comint's terminal capabilities. However, `system-uses-terminfo' describes whether the host system running Emacs uses terminfo, not whether the remote system uses it. Similarly for `comint-terminfo-terminal'.

If `comint-term-environment' were aware of connection-local variables, it would be possible to create a connection-local profile to configure this for remote hosts, e.g.:

  (connection-local-set-profile-variables
   'remote-terminfo
   '((system-uses-terminfo . t)
     (comint-terminfo-terminal . "dumb-emacs-ansi")))

  (connection-local-set-profiles
   '(:application tramp :machine "foo")
   'remote-terminfo))

(Note: "dumb-emacs-ansi" comes from the ncurses-term package[1] in Debian, and should be a good value to represent comint's capabilities.)

This lets the user pass a terminfo-friendly value for TERM to the remote system, even if the local system doesn't use terminfo. Then programs on the remote system can consult terminfo to their hearts' content.

I've attached a patch that does this, assuming the reasoning above makes sense. Perhaps it also warrants an entry in NEWS? I wasn't sure...

[1] https://packages.debian.org/buster/all/ncurses-term/filelist

Attachment: 0001-lisp-comint.el-comint-term-environment-Make-it-conne.patch
Description: Text document


--- End Message ---
--- Begin Message --- Subject: Re: bug#51426: 29.0.50; [PATCH] Should 'comint-term-environment' be connection-aware? Date: Thu, 28 Oct 2021 18:48:58 +0200 User-agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux)
Version: 29.1

Jim Porter <jporterbugs@gmail.com> writes:

Hi Jim,

> Looking at it again, I definitely agree. I've tried to reword it
> without making it too much more verbose. How's this?

Fine. I've committed this in your name to master, slightly
modified. Closing the bug.

What I'm curious about is whether we shall give more guidance using this
feature. The majority of the users don't know connection-local
variables, your example from the initial message might be instructive
for them.

WDYT?

Best regards, Michael.


--- End Message ---

reply via email to

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