[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Bug or not a bug? dot expansion in ob-shell
From: |
Bastien |
Subject: |
Re: Bug or not a bug? dot expansion in ob-shell |
Date: |
Wed, 19 Feb 2020 14:00:02 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) |
Hi Tim,
thanks for your proposal. I think we agree here.
My suggestion is to have a new option ob-shell-value-is-exit-status.
When set to nil (the default), the "return value" of a shell source
block would be the output of the last command. This is the current
behavior where we have e.g.
#+begin_src shell
echo "Hello!"
#+end_src
#+RESULTS:
: Hello!
When set to t, the return value of a shell source block would be the
exit code of the last command. This would be useful for side effect
and other use cases.
We can also consider a specific parameter :value-is-exit-code to set
for individual blocks--useful for noweb.
My only point is I don't think ob-shell-value-is-exit-status should be
t by default, as it would cause all shell blocks to return the status
code by default, which may not be what most users want.
Anyway, I don't have yet a clue on how to add this new option. I'll
leave it to Eric first (if he has time) then look at it later this
week.
Thanks!
--
Bastien
- Re: Bug or not a bug? dot expansion in ob-shell, (continued)
- Re: Bug or not a bug? dot expansion in ob-shell, Bastien, 2020/02/19
- Re: Bug or not a bug? dot expansion in ob-shell, Bastien, 2020/02/19
- Re: Bug or not a bug? dot expansion in ob-shell, Bastien, 2020/02/19
- Re: Bug or not a bug? dot expansion in ob-shell, Fraga, Eric, 2020/02/19
- Re: Bug or not a bug? dot expansion in ob-shell, Bastien, 2020/02/19
- Re: Bug or not a bug? dot expansion in ob-shell, Fraga, Eric, 2020/02/19
- Re: Bug or not a bug? dot expansion in ob-shell, Vladimir Nikishkin, 2020/02/19
- Re: Bug or not a bug? dot expansion in ob-shell, Bastien, 2020/02/19
- Re: Bug or not a bug? dot expansion in ob-shell, Bastien, 2020/02/19
- Re: Bug or not a bug? dot expansion in ob-shell, Tim Cross, 2020/02/19
- Re: Bug or not a bug? dot expansion in ob-shell,
Bastien <=
- Re: Bug or not a bug? dot expansion in ob-shell, Tim Cross, 2020/02/19
- Re: Bug or not a bug? dot expansion in ob-shell, Bastien, 2020/02/19
- Re: Bug or not a bug? dot expansion in ob-shell, Fraga, Eric, 2020/02/19
- Re: Bug or not a bug? dot expansion in ob-shell, Bastien, 2020/02/19
- Re: Bug or not a bug? dot expansion in ob-shell, Fraga, Eric, 2020/02/19
- Re: Bug or not a bug? dot expansion in ob-shell, Bastien, 2020/02/19
- Re: Bug or not a bug? dot expansion in ob-shell, Diego Zamboni, 2020/02/19
- Re: Bug or not a bug? dot expansion in ob-shell, Samuel Wales, 2020/02/19
- Re: Bug or not a bug? dot expansion in ob-shell, Bastien, 2020/02/19
- Re: Bug or not a bug? dot expansion in ob-shell, Nick Dokos, 2020/02/20