https://github.com/sergiocorreia/panflute Skip to content Toggle navigation Sign up * Product + Actions Automate any workflow + Packages Host and manage packages + Security Find and fix vulnerabilities + Codespaces Instant dev environments + Copilot Write better code with AI + Code review Manage code changes + Issues Plan and track work + Discussions Collaborate outside of code Explore + All features + Documentation + GitHub Skills + Blog * Solutions For + Enterprise + Teams + Startups + Education By Solution + CI/CD & Automation + DevOps + DevSecOps Case Studies + Customer Stories + Resources * Open Source + GitHub Sponsors Fund open source developers + The ReadME Project GitHub community articles Repositories + Topics + Trending + Collections * Pricing Search or jump to... Search code, repositories, users, issues, pull requests... Search [ ] Clear Search syntax tips Provide feedback We read every piece of feedback, and take your input very seriously. [ ] [ ] Include my email address so I can be contacted Cancel Submit feedback Saved searches Use saved searches to filter your results more quickly Name [ ] Query [ ] To see all available qualifiers, see our documentation. Cancel Create saved search Sign in Sign up You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session. You switched accounts on another tab or window. Reload to refresh your session. {{ message }} sergiocorreia / panflute Public * Notifications * Fork 58 * Star 431 An Pythonic alternative to John MacFarlane's pandocfilters, with extra helper functions scorreia.com/software/panflute/ License BSD-3-Clause license 431 stars 58 forks Star Notifications * Code * Issues 14 * Pull requests 2 * Actions * Projects 0 * Security * Insights More * Code * Issues * Pull requests * Actions * Projects * Security * Insights sergiocorreia/panflute This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository. master Switch branches/tags [ ] Branches Tags Could not load branches Nothing to show {{ refName }} default View all branches Could not load tags Nothing to show {{ refName }} default View all tags Name already in use A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch? Cancel Create 3 branches 17 tags Code * Local * Codespaces * Clone HTTPS GitHub CLI [https://github.com/s] Use Git or checkout with SVN using the web URL. [gh repo clone sergio] Work fast with our official CLI. Learn more about the CLI. * Open with GitHub Desktop * Download ZIP Sign In Required Please sign in to use Codespaces. Launching GitHub Desktop If nothing happens, download GitHub Desktop and try again. Launching GitHub Desktop If nothing happens, download GitHub Desktop and try again. Launching Xcode If nothing happens, download Xcode and try again. Launching Visual Studio Code Your codespace will open once ready. There was a problem preparing your codespace, please try again. Latest commit @sergiocorreia sergiocorreia Remove support from end-of-life Python 3.6 ... dd8b03a Mar 6, 2023 Remove support from end-of-life Python 3.6 (In anticipation of possibly adding type support) dd8b03a Git stats * 554 commits Files Permalink Failed to load latest commit information. Type Name Latest commit message Commit time .github/workflows Update run_tests.yml January 26, 2023 01:35 docs Remove support from end-of-life Python 3.6 March 6, 2023 22:14 examples Fix tests and misc. bugs November 9, 2020 01:56 extra Final documentation May 7, 2016 14:34 misc Small tweaks to docs December 10, 2019 03:10 panflute Update to Pandoc API 1.23 (Pandoc 3.0) January 26, 2023 01:05 tests Update test_walk.py January 26, 2023 01:19 .gitignore Tweak gitignore September 12, 2021 05:34 CONTRIBUTING.md tweak docs February 28, 2021 15:47 DISTRIBUTION.md Simplify setup & requirements, housekeeping November 6, 2020 18:32 LICENSE Update to Pandoc API 1.23 (Pandoc 3.0) January 26, 2023 01:05 MANIFEST.in Simplify setup & requirements, housekeeping November 6, 2020 18:32 README.md Merge branch 'master' into support-2.19 January 26, 2023 09:34 requirements.txt put back requirements.txt deleted in 478c872 November 6, 2020 18:33 setup.py Remove support from end-of-life Python 3.6 March 6, 2023 22:14 View code [ ] Panflute: Pythonic Pandoc Filters Installation Pip Conda Note on versions Supported Python versions Supported pandoc versions Dev Install Contributing License Changelog README.md Panflute: Pythonic Pandoc Filters Development Status Build Status License DOI GitHub Releases PyPI version Conda Version Python version Supported implementations panflute is a Python package that makes creating Pandoc filters fun. For a detailed user guide, documentation, and installation instructions, see http://scorreia.com/software/panflute/. For examples that you can use as starting points, check the examples repo , the sample template, or this github search. If you want to contribute, head here. You might also find useful this presentation on how I use markdown+pandoc+panflute to write research papers (at the Banco de Portugal 2019 Workshop on Reproductible Research). Installation Pip To manage panflute using pip, open the command line and run * pip install panflute to install + pip install "panflute[extras]" to include extra dependencies (yamlloader) * pip install -U panflute to upgrade * pip uninstall panflute to remove You need a matching pandoc version for panflute to work flawlessly. See [Supported pandoc versions] for details. Or, use the [Conda] method to install below to have the pandoc version automatically managed for you. Conda To manage panflute with a matching pandoc version, open the command line and run * conda install -c conda-forge pandoc 'panflute>=2.0.5' to install both conda install -c conda-forge pandoc 'panflute>=2.0.5' yamlloader to include extra dependencies * conda update pandoc panflute to upgrade both * conda remove pandoc panflute to remove both You may also replace conda by mamba, which is basically a drop-in replacement of the conda package manager. See mamba-org/mamba: The Fast Cross-Platform Package Manager for details. Note on versions Supported Python versions panflute 1.12 or above dropped support of Python 2. When using Python 3, depending on your setup, you may need to use pip3/python3 explicitly. If you need to use panflute in Python 2, install panflute 1.11.x or below. Currently supported Python versions: Python version. Check setup.py for details, which further indicates support of pypy on top of CPython. Supported pandoc versions pandoc versioning semantics is MAJOR.MAJOR.MINOR.PATCH and panflute's is MAJOR.MINOR.PATCH. Below we shows matching versions of pandoc that panflute supports, in descending order. Only major version is shown as long as the minor versions doesn't matter. panflute supported pandoc supported pandoc API version versions versions 2.3.0 2.11.0.4-3.0.x 1.22-1.23 2.2.4 2.11.0.4-2.17.x 1.22-1.22.1 2.1.x 2.11.0.4--2.14.x 1.22 2.0 2.11.0.4--2.11.x 1.22 not supported 2.10 1.21 1.12 2.7-2.9 1.17.5-1.20 Note: pandoc 2.10 is short lived and 2.11 has minor API changes comparing to that, mainly for fixing its shortcomings. Please avoid using pandoc 2.10. Dev Install After cloning the repo and opening the panflute folder, run * python setup.py install to install the package locally * python setup.py develop to install locally with a symlink so changes are automatically updated Contributing Feel free to submit push requests. For consistency, code should comply with pep8 (as long as its reasonable), and with the style guides by @kennethreitz and google. Read more here. License BSD3 license (following pandocfilters by @jgm). Changelog * 2.3.0 Update Pandoc API from 1.22 to 1.23 (Pandoc 3.0): + Add Figure block object + Remove Null block object (scheduled for removed) About An Pythonic alternative to John MacFarlane's pandocfilters, with extra helper functions scorreia.com/software/panflute/ Topics python markdown filter pandoc Resources Readme License BSD-3-Clause license Stars 431 stars Watchers 14 watching Forks 58 forks Report repository Releases 17 2.3.0 Latest Jan 26, 2023 + 16 releases Used by 416 * @lsst-sqre * @fabianhasse * @ChaosData * @GavinMcWhinnie * @ChaosData * @Paul-VS * @opgm * @pmamico + 408 Contributors 24 * @sergiocorreia * @ickc * @kiwi0fruit * @dhimmel * @chrisjsewell * @kdheepak * @jacobwhall * @hoijui * @alerque * @ekiim * @judy2k + 13 contributors Languages * Python 99.9% * TeX 0.1% Footer (c) 2023 GitHub, Inc. Footer navigation * Terms * Privacy * Security * Status * Docs * Contact GitHub * Pricing * API * Training * Blog * About You can't perform that action at this time.