From mboxrd@z Thu Jan 1 00:00:00 1970 From: Achim Gratz Subject: Re: [babel] Sh problem when echo'ing input data with ' inside Date: Mon, 17 Jan 2011 21:00:37 +0100 Message-ID: <87k4i3uwpm.fsf@Rainer.invalid> References: <80k4i3vgzo.fsf@missioncriticalit.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Return-path: Received: from [140.186.70.92] (port=59579 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PevGM-0006aR-QQ for emacs-orgmode@gnu.org; Mon, 17 Jan 2011 15:01:15 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PevGE-0004eS-QC for emacs-orgmode@gnu.org; Mon, 17 Jan 2011 15:01:07 -0500 Received: from lo.gmane.org ([80.91.229.12]:36311) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PevGE-0004eJ-KX for emacs-orgmode@gnu.org; Mon, 17 Jan 2011 15:01:06 -0500 Received: from list by lo.gmane.org with local (Exim 4.69) (envelope-from ) id 1PevG8-0006Iy-2G for emacs-orgmode@gnu.org; Mon, 17 Jan 2011 21:01:00 +0100 Received: from p57aaca5a.dip.t-dialin.net ([87.170.202.90]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Mon, 17 Jan 2011 21:01:00 +0100 Received: from Stromeko by p57aaca5a.dip.t-dialin.net with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Mon, 17 Jan 2011 21:01:00 +0100 List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: emacs-orgmode@gnu.org Sébastien Vauban writes: > However, I can't do any work on the input file, the very basic echo command > already giving an error: This is because quoting the arguments to echo does not work when your input contains unescaped quote characters. I've no idea how exactly babel tries to get it's arguments to the command, but it looks like it simply copies text and executes the resulting script? If it could open a pipe and send the data through, no quoting would be necessary since the shell never sees the data. I'm not sure if that's possible because I can't find specific documentation on language "sh". [Note: orgmode online manual links to http://orgmode.org/worg/org-contrib/babel/languages/ which is broken.] > #+begin_src sh :var data=excel-from-bank :results output > echo "$data" > #+end_src So, you're using a un*xoid? This is your lucky day, since in your case you should be able to use a here script: #+begin_src sh :var data=excel-from-bank :results output echo <+ SD adaptations for KORG EX-800 and Poly-800MkII V0.9: http://Synth.Stromeko.net/Downloads.html#KorgSDada