From: Shintaro Katayama <shintaro.katayama@gmail.com>
To: "emacs-orgmode@gnu.org" <emacs-orgmode@gnu.org>
Subject: Re: ob-shell, output and continuation prompts
Date: Sun, 04 Feb 2018 19:32:00 +0000 [thread overview]
Message-ID: <CAA0xz1M8tnMw3v8sMQ6UpsL5LgxUypxgXagfbVkEgJgeBMehyw@mail.gmail.com> (raw)
In-Reply-To: <87tvxea8x3.fsf@luisa.c0t0d0s0.de>
[-- Attachment #1: Type: text/plain, Size: 1864 bytes --]
Hi,
A similar issue - a code block and the result below would be normal.
#+BEGIN_SRC shell
echo $PWD
#+END_SRC
#+Results:
: /Users/shin/Documents
However, when I specified a session name, the first evaluation returns a
table-format value as below, ...
#+BEGIN_SRC shell :session *shell*
echo $PWD
#+END_SRC
#+Results:
| |
| /Users/shin/Documents |
... but, the second or more latter evaluations return the normal value.
#+BEGIN_SRC shell :session *shell*
echo $PWD
#+END_SRC
#+Results:
: /Users/shin/Documents
... How can I get the normal value in all evaluations of the session?
I attached the session log in the *shell* buffer below. I am using Org mode
version 9.1.6 (9.1.6-16-g86a382-elpaplus @
/Users/shin/.emacs.d/elpa/org-plus-contrib-20180115/ on macOS.
Regards,
Shintaro
----
echo $PWD
bash-3.2$ /Users/shin/Documents
bash-3.2$ echo 'org_babel_sh_eoe'
org_babel_sh_eoe
bash-3.2$ echo $PWD
/Users/shin/Documents
bash-3.2$ echo 'org_babel_sh_eoe'
org_babel_sh_eoe
bash-3.2$
----
On Tue, Nov 28, 2017 at 1:25 PM Michael Welle <mwe012008@gmx.net> wrote:
> Hello,
>
> this code block:
>
> #+BEGIN_SRC shell :session n42 :shebang "#!/bin/bash"
> for i in "aa" "bb" "cc" ; do
> echo "u: $i"
> done
> #+end_src
>
> produces this output when it first runs:
>
> #+RESULTS:
> | | | | |
> | > | > | u: | aa |
> | u: | bb | | |
> | u: | cc | | |
>
>
> After the first run, subsequent runs produce this output:
>
> #+RESULTS:
> | | | |
> | > | u: | aa |
> | u: | bb | |
> | u: | cc | |
>
> If I set :session to none the output is always like follows:
>
> #+RESULTS:
> | u: | aa |
> | u: | bb |
> | u: | cc |
>
>
> I think that last one is what one would expect ;). Anyways, using sessions,
> is there a way to get rid off of the shell's continuation prompts?
>
> Regards
> hmw
>
>
[-- Attachment #2: Type: text/html, Size: 2994 bytes --]
prev parent reply other threads:[~2018-02-04 19:32 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-11-28 12:23 ob-shell, output and continuation prompts Michael Welle
2017-11-28 13:00 ` Eric S Fraga
2017-11-28 13:06 ` Michael Welle
2017-11-28 13:19 ` Michael Welle
2018-02-04 19:32 ` Shintaro Katayama [this message]
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=CAA0xz1M8tnMw3v8sMQ6UpsL5LgxUypxgXagfbVkEgJgeBMehyw@mail.gmail.com \
--to=shintaro.katayama@gmail.com \
--cc=emacs-orgmode@gnu.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).