emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: "Sébastien Vauban" <wxhgmqzgwmuf-geNee64TY+gS+FvcfC7Uqw@public.gmane.org>
To: emacs-orgmode-mXXj517/zsQ@public.gmane.org
Subject: Re: [babel] Sh problem when echo'ing input data with ' inside
Date: Tue, 18 Jan 2011 18:31:12 +0100	[thread overview]
Message-ID: <804o96dspr.fsf@missioncriticalit.com> (raw)
In-Reply-To: 87y66idvmi.fsf@gmail.com

Hi Eric,

"Eric Schulte" wrote:
>> I asked the question on the Cygwin mailing list, and got an answer from Tobias
>> Schlottke, telling me to use the 'plain old' syntax (=`...`= instead of
>> =$(...)=):
>>
>> #+begin_src sh
>> data=`cat <<EOF
>> ...
>> EOF
>> `
>> echo "$data"
>> #+end_src
>>
>> and... it indeed works!
>>
>> Can we move to that syntax?
>
> I just made this customizable, after a git pull the following elisp code
> will use that syntax on your system.
>
> #+begin_src emacs-lisp
>   (setq org-babel-sh-var-quote-fmt "`cat <<'BABEL_TABLE'\n%s\nBABEL_TABLE\n`")
> #+end_src

That's, indeed, better than what I had in mind, as it now is customizable...
... and, of course, that does the trick!

Thanks a lot for your prompt fix.

BTW, I would, though, advice to make this the default, as it should be fully
functional under any Linux, and then would be directly usable by any user on
Windows/Cygwin, without having to wonder why sh code blocks don't work the way
they should.

Best regards,
  Seb

-- 
Sébastien Vauban


_______________________________________________
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode-mXXj517/zsQ@public.gmane.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode

  reply	other threads:[~2011-01-18 17:31 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-01-17 12:42 [babel] Sh problem when echo'ing input data with ' inside Sébastien Vauban
2011-01-17 16:24 ` Eric Schulte
2011-01-17 19:29   ` Sébastien Vauban
2011-01-17 19:54     ` Eric Schulte
2011-01-17 22:49       ` Sébastien Vauban
2011-01-17 20:00 ` Achim Gratz
2011-01-17 20:29   ` Eric Schulte
2011-01-17 21:36   ` Achim Gratz
2011-01-17 22:39     ` Sébastien Vauban
2011-01-17 22:51       ` Achim Gratz
2011-01-18  7:02         ` Sébastien Vauban
2011-01-18  9:22       ` Sébastien Vauban
2011-01-18 16:24         ` Eric Schulte
2011-01-18 17:31           ` Sébastien Vauban [this message]
2011-01-18 18:23         ` Achim Gratz
2011-01-20 19:17         ` Achim Gratz
2011-01-20 22:12           ` Sébastien Vauban

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

  List information: https://www.orgmode.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=804o96dspr.fsf@missioncriticalit.com \
    --to=wxhgmqzgwmuf-genee64ty+gs+fvcfc7uqw@public.gmane.org \
    --cc=emacs-orgmode-mXXj517/zsQ@public.gmane.org \
    /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 public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).