From: "Eric Schulte" <schulte.eric@gmail.com>
To: "Sébastien Vauban" <wxhgmqzgwmuf@spammotel.com>
Cc: emacs-orgmode@gnu.org
Subject: Re: Re: [Babel] Reporting 2 problems of code execution
Date: Thu, 02 Dec 2010 12:40:42 -0700 [thread overview]
Message-ID: <878w087ykl.fsf@gmail.com> (raw)
In-Reply-To: <80y6888ql1.fsf@missioncriticalit.com> ("Sébastien Vauban"'s message of "Thu, 02 Dec 2010 10:35:38 +0100")
Sébastien Vauban <wxhgmqzgwmuf@spammotel.com> writes:
> Hi Eric,
>
> "Eric Schulte" wrote:
>> Sébastien Vauban <wxhgmqzgwmuf@spammotel.com> writes:
>>> You're right that could be it. I often forget about adding that setting, even
>>> though it's more or less mandatory for the sh blocks -- at least, in many sh
>>> blocks I write...
>>
>> You can specify this as the default header argument for all shell blocks
>> with the following.
>>
>> #+begin_src emacs-lisp
>> (add-to-list 'org-babel-default-header-args '((:results . "output")))
>> #+end_src
>
> Thanks for the tip but... that may be a bit drastic, I mean forcing every
> snippet of *every language* to behave like that:
He Seb,
Sorry I miss-typed, I meant the following which is exactly your
suggestion below.
#+begin_src emacs-lisp
(add-to-list 'org-babel-default-header-args:sh '((:results . "output")))
#+end_src
> I'm convinced it's the most natural choice for sh blocks, but maybe
> the less natural (i.e., must be overridden) for all other programming
> languages.
>
> In fact, I have the strong impression that we should need this on a language
> basis, something like:
>
> #+begin_src emacs-lisp
> (add-to-list 'org-babel-default-header-args '(
> (sh . (:results . "output"))
> (emacs-lisp . (:results . "value"))))
> #+end_src
>
> I feel the same about the Babel "file" property:
>
> #+BABEL: :engine mysql :cmdline -S server -U sa -P secret -d storeall
> -n -w 700 -s " "
>
> Not being able to specify the language these defaults apply to may rapidly
> lead to clashes... Or we have to set the default for the language for which we
> have the biggest number of chunks, and explicitly set the values for all the
> other snippets that are written in other languages.
>
> Maybe allowing such a specification line?
>
> #+BABEL sql: :engine mysql :cmdline -S server -U sa -P secret -d
> storeall -n -w 700 -s " "
>
That seems like a good suggestion, the only question seems to be what is
the most natural syntax.
I think I would lean more towards something like
#+SQL_SOURCE:
Best -- Eric
>
> Best regards,
> Seb
next prev parent reply other threads:[~2010-12-02 19:40 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-11-28 20:04 [Babel] Reporting 2 problems of code execution Sébastien Vauban
2010-11-29 4:34 ` Charles C. Berry
2010-11-29 9:03 ` Sébastien Vauban
2010-11-29 16:47 ` Charles C. Berry
2010-11-29 19:49 ` Dan Davison
2010-11-30 2:03 ` Eric Schulte
2010-12-02 9:35 ` Sébastien Vauban
2010-12-02 19:40 ` Eric Schulte [this message]
2010-12-02 19:58 ` Sébastien Vauban
2010-12-05 15:39 ` Eric Schulte
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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=878w087ykl.fsf@gmail.com \
--to=schulte.eric@gmail.com \
--cc=emacs-orgmode@gnu.org \
--cc=wxhgmqzgwmuf@spammotel.com \
/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 external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.