From: "H. Dieter Wilhelm" <dieter@duenenhof-wilhelm.de>
To: Michael Powe <powem@ctpowe.net>
Cc: emacs-orgmode@gnu.org
Subject: Re: Shell SRC blocks under Windows
Date: Sat, 05 Feb 2022 16:48:02 +0100 [thread overview]
Message-ID: <xm46pmo1gvrh.fsf@duenenhof-wilhelm.de> (raw)
In-Reply-To: <57a07903-cb7a-67ab-7a93-c6d03654c17e@ctpowe.net> (Michael Powe's message of "Fri, 4 Feb 2022 16:45:15 -0500")
Michael Powe <powem@ctpowe.net> writes:
> On 2/4/2022 15:15, H. Dieter Wilhelm wrote:
>> Hello
>>
>> I installed the software distribution MSYS2 https://www.msys2.org/. And
>> I'd like to call its various shells in org src blocks. First I tried to
>> set explicit-shell-file-name but then my LaTeX exports don't work any
>> longer.
>>
>> Is is it possible to extend org-mode's src blocks with
>> org-babel-shell-names to use either MSYS2 or MinGW shells (instead of
>> cmd.exe)? Unfortunately ob-shell.el doesn't guide me further and I
>> can't find examples or the respective lisp files on how to define the
>> execution functions.
>>
>> GNU Emacs 28.0.91 (build 1, x86_64-pc-linux-gnu, GTK+ Version 3.22.30,
>> cairo version 1.15.10) of 2022-01-14
>>
>> Org mode version 9.4.6 (9.4.6-13-g4be129-elpaplus @
>> /home/dieter/.emacs.d/elpa/org-plus-contrib-20210920/)
>
> I'm not aware that I did anything special to get these results, except
> add `(shell . t)` to `org-babel-load-languages`. I mean, it is entirely
> possible that I did, in some other context. I think it's just a matter
> of having bash in your path.
Yes, you are right, when using
> #+begin_src sh
It seems that I'm also running some bash shell! :-) Previously I was
using the src block in this way:
#+begin_src shell
and here the shell seems to be com.exe.
But I'm not sure if I'm halfway there with "sh"? I need to run the
following MSYS2 command AND switch between two arguments (for building
Emacs).
\MSYS2\msys2_shell.cmd -mingw64
and
\MSYS2\msys2_shell.cmd -msys.
How could I achieve this within a src block?
Thanks
next prev parent reply other threads:[~2022-02-05 15:49 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-02-04 20:15 Shell SRC blocks under Windows H. Dieter Wilhelm
2022-02-04 21:45 ` Michael Powe
2022-02-05 15:48 ` H. Dieter Wilhelm [this message]
2022-02-05 22:22 ` Matt
2022-02-06 15:46 ` Matt
2022-02-06 17:51 ` H. Dieter Wilhelm
2022-02-07 12:57 ` Matt
2022-02-08 9:47 ` H. Dieter Wilhelm
2022-02-08 22:48 ` Matt
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=xm46pmo1gvrh.fsf@duenenhof-wilhelm.de \
--to=dieter@duenenhof-wilhelm.de \
--cc=emacs-orgmode@gnu.org \
--cc=powem@ctpowe.net \
/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).