[O] org-babel: remote execution ?

2013-03-12 Thread Xavier Maillard
Hi there,

I am trying to get back to orgmode after years ;)

I developed my own spartian note-jotting mode for emacs but I do not
track my TODOs with that and thus, I am totally dis-org-anized :D
I am also an eev-mode fan to do all sort of stuff.

Today, I tried to use org-babel for the first time with thing like that:

#+begin_src sh
echo $ORACLE_SID
#+end_src

My goal is to execute this block on a remote machine. I RTFM'ed but I
could not find where this is described.

Is it just possible to do that ? If not, are there any eev+org users
here ?

Regards

Thank you very much for your help.

/Xavier




Re: [O] org-babel: remote execution ?

2013-03-12 Thread Eric Schulte
Xavier Maillard xav...@maillard.im writes:

 Hi there,

 I am trying to get back to orgmode after years ;)


Welcome back!


 I developed my own spartian note-jotting mode for emacs but I do not
 track my TODOs with that and thus, I am totally dis-org-anized :D I am
 also an eev-mode fan to do all sort of stuff.

 Today, I tried to use org-babel for the first time with thing like that:

 #+begin_src sh
 echo $ORACLE_SID
 #+end_src

 My goal is to execute this block on a remote machine. I RTFM'ed but I
 could not find where this is described.


You can use the :dir header argument for remote execution.

#+begin_src sh :dir /ssh:tortilla:/tmp/
  hostname
#+end_src

#+RESULTS:
: tortilla

-- 
Eric Schulte
http://cs.unm.edu/~eschulte



Re: [O] org-babel: remote execution ?

2013-03-12 Thread Xavier Maillard
Eric Schulte schulte.e...@gmail.com writes:

 Xavier Maillard xav...@maillard.im writes:

[ SNIP ]

 Today, I tried to use org-babel for the first time with thing like that:

 #+begin_src sh
 echo $ORACLE_SID
 #+end_src

 My goal is to execute this block on a remote machine. I RTFM'ed but I
 could not find where this is described.


 You can use the :dir header argument for remote execution.

 #+begin_src sh :dir /ssh:tortilla:/tmp/
   hostname
 #+end_src

 #+RESULTS:
 : tortilla

Great ! I will try that then. Does it mimic TRAMP syntax thus I could
also use also telnet or anything supported by TRAMP ?

Thnak you.

/Xavier




Re: [O] org-babel: remote execution ?

2013-03-12 Thread Eric Schulte
Xavier Maillard xav...@maillard.im writes:

 Eric Schulte schulte.e...@gmail.com writes:

 Xavier Maillard xav...@maillard.im writes:

 [ SNIP ]

 Today, I tried to use org-babel for the first time with thing like that:

 #+begin_src sh
 echo $ORACLE_SID
 #+end_src

 My goal is to execute this block on a remote machine. I RTFM'ed but I
 could not find where this is described.


 You can use the :dir header argument for remote execution.

 #+begin_src sh :dir /ssh:tortilla:/tmp/
   hostname
 #+end_src

 #+RESULTS:
 : tortilla

 Great ! I will try that then. Does it mimic TRAMP syntax thus I could
 also use also telnet or anything supported by TRAMP ?


Yes,

In fact it uses tramp.  See http://orgmode.org/manual/dir.html.

Cheers,


 Thnak you.

 /Xavier



-- 
Eric Schulte
http://cs.unm.edu/~eschulte