unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* process-tty-name of processes on remote hosts
@ 2010-07-28 12:28 Michael Albinus
  2010-07-28 22:39 ` Stefan Monnier
  0 siblings, 1 reply; 3+ messages in thread
From: Michael Albinus @ 2010-07-28 12:28 UTC (permalink / raw)
  To: emacs-devel

While working on tramp and gdb-mi for Bug#4604 and Bug#6360, there has
been a problem with `process-tty-name'. For processes started by
`start-file-process' this function returns the tty name of the local
host the process is bound to. This is not sufficient; sometimes the tty
name on the remote host must be known.

A solution by a file name handler is not possible; `process-tty-name'
does not know about magic file names.

One possiblity would be to introduce a new function
`set-process-tty-name', which could be called by Tramp, and which would
allow `process-tty-name' to return the proper value.

If it shall be still supported to distinguish the "local" and "remote"
tty names, a new function `process-remote-tty-name' could be introduced,
which DTRT.

Or Tramp simply sets a process property 'remote-tty, which could be
checked by other packages with

  (or (process-get proc 'remote-tty)
      (process-tty-name proc))

What do people think?

Best regards, Michael.



^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: process-tty-name of processes on remote hosts
  2010-07-28 12:28 process-tty-name of processes on remote hosts Michael Albinus
@ 2010-07-28 22:39 ` Stefan Monnier
  2010-07-29 14:00   ` Michael Albinus
  0 siblings, 1 reply; 3+ messages in thread
From: Stefan Monnier @ 2010-07-28 22:39 UTC (permalink / raw)
  To: Michael Albinus; +Cc: emacs-devel

> Or Tramp simply sets a process property 'remote-tty, which could be
> checked by other packages with

>   (or (process-get proc 'remote-tty)
>       (process-tty-name proc))

> What do people think?

I have no idea how important/useful it might be in general, so the above
sounds like a good solution: cheap and acceptably generic.


        Stefan



^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: process-tty-name of processes on remote hosts
  2010-07-28 22:39 ` Stefan Monnier
@ 2010-07-29 14:00   ` Michael Albinus
  0 siblings, 0 replies; 3+ messages in thread
From: Michael Albinus @ 2010-07-29 14:00 UTC (permalink / raw)
  To: Stefan Monnier; +Cc: emacs-devel

Stefan Monnier <monnier@iro.umontreal.ca> writes:

>>   (or (process-get proc 'remote-tty)
>>       (process-tty-name proc))
>
> I have no idea how important/useful it might be in general, so the above
> sounds like a good solution: cheap and acceptably generic.

Committed.

>         Stefan

Best regards, Michael.



^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2010-07-29 14:00 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-07-28 12:28 process-tty-name of processes on remote hosts Michael Albinus
2010-07-28 22:39 ` Stefan Monnier
2010-07-29 14:00   ` Michael Albinus

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).