From: Sam Steingold <sds@gnu.org>
To: emacs-devel@gnu.org
Cc: Vitalie Spinu <spinuvit@gmail.com>
Subject: Re: tramp:sshx:(screen|tmux)
Date: Thu, 07 May 2015 09:33:29 -0400 [thread overview]
Message-ID: <m2pp6cseae.fsf@gnu.org> (raw)
In-Reply-To: ruu61gvngys.fsf@svesorm0.corp.w3data.com
> * Svend Sorensen <firaq@pvssre.arg> [2014-09-10 17:22:51 -0700]:
>
> joakim@verona.se writes:
>
> > Michael Albinus <michael.albinus@gmx.de> writes:
>>
>> I have used dtach for this, albeit in a slightly different context.
>> Maybe dtach can be of use for tramp?
>
> I use the following function to start a remote shell running dtach.
>
> (defun ssh-dtach (host)
> "Open SSH connection to HOST and start dtach session."
> (interactive (list (ssh-host-completing-read)))
> (let ((explicit-shell-file-name "dtach")
> (explicit-dtach-args '("-A" "/tmp/emacs.dtach" "-z"
> "/bin/bash" "--noediting" "-login"))
> (default-directory (format "/ssh:%s:" host)))
> (shell (format "*ssh %s*" host))))
It turned out that dtach does indeed do what I need:
http://stackoverflow.com/questions/16819248/emacs-tramp-over-an-unreliable-connection
(defvar R-remote-host "remote-server")
(defvar R-remote-session "R")
(defun R-remote (&optional remote-host session)
"Connect to the remote-host's dtach session running R."
(interactive (list
(read-from-minibuffer "R remote host: " R-remote-host)
(read-from-minibuffer "R remote session: " R-remote-session)))
(pop-to-buffer (make-comint (concat "remote-" session)
"ssh" nil "-t" "-t" remote-host
"dtach" "-A" (concat ".dtach-" session)
"-z" "-E" "-r" "none"
inferior-R-program-name "--no-readline"
inferior-R-args))
(ess-remote (process-name (get-buffer-process (current-buffer))) "R")
(setq comint-process-echoes t))
--
Sam Steingold (http://sds.podval.org/) on darwin Ns 10.3.1347
http://www.childpsy.net/ http://memri.org http://mideasttruth.com
http://thereligionofpeace.com http://www.memritv.org http://think-israel.org
Democrats, get out of my wallet! Republicans, get out of my bedroom!
next prev parent reply other threads:[~2015-05-07 13:33 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-09-09 18:38 tramp:sshx:(screen|tmux) Sam Steingold
2014-09-10 13:55 ` tramp:sshx:(screen|tmux) Michael Albinus
2014-09-10 14:12 ` tramp:sshx:(screen|tmux) joakim
2014-09-10 15:09 ` tramp:sshx:(screen|tmux) Sam Steingold
2014-09-10 18:06 ` tramp:sshx:(screen|tmux) Michael Albinus
2014-09-10 18:42 ` tramp:sshx:(screen|tmux) Stefan Monnier
2014-09-11 0:22 ` tramp:sshx:(screen|tmux) Svend Sorensen
2015-05-07 13:33 ` Sam Steingold [this message]
2014-09-10 15:06 ` tramp:sshx:(screen|tmux) Sam Steingold
2014-09-10 17:56 ` tramp:sshx:(screen|tmux) Michael Albinus
2014-09-10 18:37 ` tramp:sshx:(screen|tmux) Stefan Monnier
2014-09-11 19:41 ` tramp:sshx:(screen|tmux) David Caldwell
2014-09-11 20:26 ` tramp:sshx:(screen|tmux) 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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=m2pp6cseae.fsf@gnu.org \
--to=sds@gnu.org \
--cc=emacs-devel@gnu.org \
--cc=spinuvit@gmail.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 external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.