emacs-orgmode
[Top][All Lists]
Advanced

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

Re: [Orgmode] [babel] Executing sh-code


From: Torsten Wagner
Subject: Re: [Orgmode] [babel] Executing sh-code
Date: Fri, 27 Nov 2009 19:00:08 +0900
User-agent: KMail/1.12.2 (Linux/2.6.31-15-generic; KDE/4.3.2; x86_64; ; )

Hi Sébastien,

I just tried quickly. I use org-babel with python, up to now never with shell 
scripting.

> 
> --8<---------------cut here---------------start------------->8---
> * Prerequisites
> 
> #+begin_src sh :session ecm
>     cd ~/Personal
> #+end_src
> --8<---------------cut here---------------end--------------->8---


This works for me (I changed the folder name). There is a error line in my 
message buffer
--8<---------------cut here---------------start------------->8---
executing Shell source code block
~/babel 
save-current-buffer: Wrong type argument: char-or-string-p, nil
--8<---------------cut here---------------end------------->8---


but the relevent part runs ok. My shell buffer depict to the new folder after 
execution.


--8<---------------cut here---------------start------------->8---
address@hidden ~ % 
cd ~/babel
echo 'org_babel_sh_eoe'
address@hidden ~ % cd ~/babel
address@hidden ~/babel (git)-[master] %
--8<---------------cut here---------------end------------->8---


I used the same init like you

> What am I doing wrong?  Or have I set something wrong (or missing) in my
> .emacs file?
> 
> --8<---------------cut here---------------start------------->8---
> (require 'org-babel-init)
> 
> ;; activate a subset of languages
> (require 'org-babel-R)
> (require 'org-babel-sh)
> 
> ;; make pre-built helper functions available
> (org-babel-load-library-of-babel)
> --8<---------------cut here---------------end--------------->8---

However I didn't use the (org-babel-load-library-of-babel) function.

Which version of org-mode di you use ? org-babel is young and change still 
heavily. I guess you have to use the latest git-version of org-mode.
Furthermore, does the shell iteself (M-x shell) work in emacs as desired ?

Sorry not a big help at least a pointer that it should work...

Bye

Torsten




reply via email to

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