Dear Vitalie, and Dear mailing list,

This is exactly what I wanted. I have adjusted my emacs with the
suggestions from the stackoverflow post. I have found particularly useful
the package in
http://www.emacswiki.org/emacs/essh

Many thanks for all the help.

Tiago


On Wed, Apr 3, 2013 at 6:50 PM, Vitalie Spinu <spinuvit@gmail.com> wrote:

>
> Hi Tiago,
>
> See this stackoverflow question [1]. The answer does precisely what you
> want
> in one blow. If invoked with no active region it sends the current
> line. If region is active it sends the region. That is similar to the
> behavior of C-RET in ESS (ess-eval-region-or-line-and-step).
>
> HTH,
>     Vitalie
>
> [1]
> http://stackoverflow.com/questions/6286579/emacs-shell-mode-how-to-send-region-to-shell
>
>
>   >> Tiago R M <tiago17@gmail.com>
>   >> on Wed, 3 Apr 2013 18:35:58 +0100 wrote:
>
>  > Dear mailing list,
>  > Some years ago I got very valuable help in this mailing list to push a
> line
>  > to a bottom window.
>  > https://stat.ethz.ch/pipermail/ess-help/2008-November/004949.html
>
>  > The solution came from Tim Hesterberg:
>  > (fset 'push-line-other-window
>  >       "\C-@\C-e\M-w\C-n\C-a\C-xo\M->\C-y\C-m\C-xo")
>  > (global-set-key "\C-i" 'push-line-other-window )
>  > (define-key esc-map "o" 'push-line-other-window)
>
>  > I wanted to do exactly the same but pushing a highlighted region,
> composed
>  > of several lines, not only a single line.
>
>  > (Basically what I want to do is to emulate the C-c C-r command in ESS,
> but
>  > when the bottom window is a shell command, not an R process)
>
>  > Thank you for any possible help,
>  > Tiago R Magalhaes
>
>  >      [[alternative HTML version deleted]]
>
>  > ______________________________________________
>  > ESS-help@r-project.org mailing list
>  > https://stat.ethz.ch/mailman/listinfo/ess-help
>



-- 
http://agitar-antes-de-usar.blogspot.com/

	[[alternative HTML version deleted]]

