Skip to main content

pandoc-source-exec

pandoc-source-exec is a panflute pandoc filter.

It executes code annotated code blocks with the proper executables and adds the output below. Example:

```{ .python .exec }
print('Hello World')
```

The above can be compiled like this:

example.pdf: example.md example.py
    pandoc --filter pandoc-source-exec -o $@ $<

The resulting output will include Hello World after the code block.

pandoc-source-exec offers many other features, including tikz plots, proper figures and code listings as well as including files as code.

For more examples check the example files.

Installation

Just use pip to install it from pypi

pip install pandoc-source-exec

Future

  • Execute code other than python

  • Refactor interactive execution, build REPL wrappers.

  • Allow configurable pre- and postfixes for the output

Metadata

Release files for pandoc-source-exec 0.2.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for pandoc-source-exec 0.2.2
File Size Uploaded
pandoc-source-exec-0.2.2.tar.gz 7.2 kB Details

Release files / pandoc-source-exec-0.2.2.tar.gz

Download URL pandoc-source-exec-0.2.2.tar.gz
Size 7.2 kB
Tags Source
SHA-256 checksum
How to use checksums
89f9650b0d710c9cd25a84c048885375f6bb4a2e51ec4c429ee3f777a1f204a6
BLAKE2b-256 checksum
How to use checksums
049c33ca822f74ecb477e1dde5d8a878d9f77519b988352cb00fb25d555f9102
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/3.7.3

Release history Release notifications | RSS feed

This release

0.2.2 This release

1 release file

0.2.1

1 release file

0.2.0

1 release file

0.1.4

1 release file

0.1.3

1 release file

0.1.2

1 release file

0.1.1

1 release file

0.1.0

1 release file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page