[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Global variables in Org mode document with source blocks
From: |
Lennart C. Karssen |
Subject: |
Re: Global variables in Org mode document with source blocks |
Date: |
Tue, 25 May 2021 16:27:50 +0200 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.8.1 |
Hi Greg,
On 18-05-2021 19:25, Greg Minshall wrote:
> Lennart,
>
> John's idea seems good. also, you could generate a separate RESULT for
> each language, then :var each language's "failed" RESULT into your bash
> block and fail if any of them are set?
The main problem I see with that solution is that my code blocks print
raw Org code/text, e.g. tables of results or a paragraph of text that
depends on the computations done in the code blocks. I haven't tried,
but passing and parsing those multiline RESULT blocks into a final
'conclusion' block is probably not very easy.
I ended up going for a slightly adapted version of John's first idea:
Adding a # failure-CODE line to any block that fails. That line is
ignored on export to PDF, but can still be counted in a final code block
that searches the buffer for matching regexps.
Thanks for your input.
Lennart.
>
> cheers, Greg
>
--
*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*
L.C. Karssen
's-Hertogenbosch
The Netherlands
lennart@karssen.org
http://blog.karssen.org
GPG key ID: A88F554A
-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-
OpenPGP_signature
Description: OpenPGP digital signature