@pandoc@fosstodon.org
@pandoc@fosstodon.org avatar

pandoc

@pandoc@fosstodon.org

Tips and news about #pandoc, the universal document converter. Run by https://scholar.social/@tarleb.

All posts made from this account are licensed under CC BY 4.0.

This profile is from a federated server and may be incomplete. Browse more on the original instance.

pandoc, (edited ) to random
@pandoc@fosstodon.org avatar

#Pandoc contains an interactive #Lua REPL (since 3.1.2). Start it with

pandoc lua -i

Enable a persistent command history by setting the PANDOC_REPL_HISTORY environment variable to a filename. Use arrow keys to step through the history, or search it with ctrl-r.

pandoc, to random
@pandoc@fosstodon.org avatar

Getting support for #pandoc
• The "Discussions" forum on GitHub has become the central place for community support: https://github.com/jgm/pandoc/discussions
• A wealth of knowledge can be found in the archive of the pandoc-discuss mailing list https://inbox.vuxu.org/pandoc-discuss/
• Likewise, there are many Q&As tagged "pandoc" on StackOverflow: https://stackoverflow.com/questions/tagged/pandoc
• Questions posted here may sometimes go without an answer, but I generally try to reply.

pandoc, to random
@pandoc@fosstodon.org avatar

New logo. Let us know your thoughts, and/or propose improvements here:
https://github.com/tarleb/pandoc-logo

pandoc,
@pandoc@fosstodon.org avatar

@david Thank you for the feedback, much appreciated! I've shortened the top bar a little, that should make it easier to read it as a P (and as a reverse pilcrow ⁋).

pandoc, (edited ) to random
@pandoc@fosstodon.org avatar

A number of formats, including #EPUB, #ODT, #docx, and #PDF (via #TeXLaTeX, #Typst, ...) include the document's build time. This can be an issue for reproducible builds. Set the SOURCE_DATE_EPOCH environment variable to an integer value¹ to use a fixed time instead.

SOURCE_DATE_EPOCH=682984800 pandoc …

¹ Seconds in the Unix epoch. Get the current epoch time with date +%s.

#pandoc #reproduciblebuilds

pandoc, to random
@pandoc@fosstodon.org avatar

Below is a custom #Lua writer that behaves like a built-in writer. It can serve as the basis for a modified writer, e.g., one with a programmatically modified template.
https://pandoc.org/custom-writers

local format = 'commonmark'

Extensions = pandoc.format.extensions(format)
Template = pandoc.template.default(format)
Writer = function (doc, opts)
return pandoc.write(doc, {format=format, extensions=opts.extensions}, opts)
end

#pandoc #Lua

pandoc,
@pandoc@fosstodon.org avatar

@baptnz The example in the docs is mildly outdated, but can hopefully still convey the basic idea.
https://pandoc.org/custom-writers#example-modified-markdown-writer

pandoc, to random
@pandoc@fosstodon.org avatar

Writing one sentence per line can make collaborating via source control systems (like git) more convenient. Here's a #pandoc #LuaFilter that does that:
https://gist.github.com/tarleb/ef395339d4ce8d940cae0c48e5de9e82

pandoc, to opensource
@pandoc@fosstodon.org avatar

It's nice to see a company with a clear commitment to #opensource software (and democracy) be successful in the #publishing space. Congratulations to your 25th company anniversary, @letexml!

pandoc, to random
@pandoc@fosstodon.org avatar

🆕 release of section-bibliographies v1.0.0, a #pandoc #LuaFilter that allows to produce separate bibliographies for each chapter or section. Works with #Quarto, too.
The new version comes with a number of performance improvements, as well as additional customization options.
https://github.com/pandoc-ext/section-bibliographies

pandoc, to typst
@pandoc@fosstodon.org avatar

See https://pandoc.org/typst-property-output for more info about the new property support introduced in 3.2.

pandoc,
@pandoc@fosstodon.org avatar

@dginev Style conversions are out of scope for pandoc. But see the Lua filter example on how to map properties.

pandoc, to random
@pandoc@fosstodon.org avatar

🆕 pandoc 3.2 is out!
Most significant changes:

  • Typst output became more custimizable.
  • custom-style started to work with ODT.
  • Better Lua support for logging, image handling.

Find the full release notes here:
https://github.com/jgm/pandoc/releases/tag/3.2

Many thanks to all who contributed! 🫶

pandoc,
@pandoc@fosstodon.org avatar

On a personal note: this release also marks (±4 days) the 10 year anniversary of the release that contained my first contributions. That was pandoc 1.12.4, released May 7th, 2014.
I'm happy that pandoc is still going strong. Many thanks to all users, contributors, and the community as a whole for making this such a pleasant experience!

jfdm, to orgmode

It always annoys me that both and do not appear to have a 'clean'/plain flag for generating output.

I want 'plain' LaTeX and HTML with no additions or custom elements...no \tightlist in list environments, nor <div> around sections. Just plain unadulterated markup, that is all...

pandoc,
@pandoc@fosstodon.org avatar

@jfdm I can relate, but the decision was made a while ago not to support this: https://github.com/jgm/pandoc/issues/8249
However, more cases like \tightlist have been creeping in recently, so it might be worth to bring it up again in a discussion.
https://github.com/jgm/pandoc/discussions
Specifically for tightlists: there's a StackOverflow Q&A about the opposite problem, but the solution could be adjusted to do the reverse, i.e. remove all tight lists by switching Plain and Para. https://stackoverflow.com/q/57940840/2425163

pandoc,
@pandoc@fosstodon.org avatar

@jfdm One option for academic writing could be . It uses pandoc under the hood, but has scientific publishing set as one of the goals. See, e.g., https://quarto.org/docs/extensions/listing-journals.html
Any LaTeX acceptance problems would be treated as a bug there, I'd assume.

pandoc, to random
@pandoc@fosstodon.org avatar

@mxp wrote a small #pandoc #LuaFilter that helps to preserve DOI info when converting from #BibLaTeX to #BibTeX.
https://gist.github.com/mxpiotrowski/0e7d26980db8554b62ca61a476adc958

pandoc, to random
@pandoc@fosstodon.org avatar

The images had been experiencing some bit-rot, but have been updated and are back in service now. The images include the latest release (3.1.13) and the current development version. They continue to be available in the four flavors minimal, core, latex, and extra.
images now ship with 2024.

https://hub.docker.com/r/pandoc/minimal
https://hub.docker.com/r/pandoc/core
https://hub.docker.com/r/pandoc/latex
https://hub.docker.com/r/pandoc/extra

pandoc, to random
@pandoc@fosstodon.org avatar

Small example of how the #Lua subsystem can be used to query #pandoc's capabilities:
The default binary allows to --list-extensions of a given format, but there is no analogous option to list all formats which work with a given extension, so here is a pandoc Lua program that provides this functionality: https://gist.github.com/tarleb/ef63974ab18d92acf0eb40180d832c48

pandoc, to random
@pandoc@fosstodon.org avatar

Support for alert-boxes was added in pandoc 3.1.10.

> [!INFO]
> This is an informational message.

Note, however, that writer (i.e., rendering) support for this is limited, and that the alert extension works with CommonMark, but not with pandoc-flavored Markdown.

The syntax has been made popular by GitHub: https://docs.github.com/en/get-started/writing-on-github/getting-started-with-writing-and-formatting-on-github/basic-writing-and-formatting-syntax#alerts

pandoc, to accessibility
@pandoc@fosstodon.org avatar

Starting with version 3.1.12, #pandoc-generated #EPUBs conform to the EU Accessibility Act. https://www.w3.org/TR/epub-a11y-eaa-mapping/

Relevant metadata fields are listed in the "EPUB metadata" section of the manual: https://pandoc.org/MANUAL#epub-metadata.

#accessibility #A11y

pandoc, (edited ) to random
@pandoc@fosstodon.org avatar

The default LaTeX template in #pandoc v3.1.12 and later supports font fallbacks. The fallback is used if a glyph cannot be found in a font.
Example use-case: get color emojis in #PDF.


mainfontfallback:

  • Noto Color Emoji

🌻

Requires #LuaLaTeX as the PDF engine (i.e., pandoc --pdf-engine=lualatex ...). #TeXLaTeX
Alternatively, try 'NotoColorEmoji:mode=harf'.

pandoc,
@pandoc@fosstodon.org avatar

@tennoseremel Thanks, you're right, of course!

pandoc, to random
@pandoc@fosstodon.org avatar

A spam attack on the pandoc-discuss mailing list hosted on Google Groups caused a suspension of the entire list. Google is not responding to requests to re-enable the list.
For the time being, please use the GitHub Discussion feature. Whether this will become a permanent solution is currently not clear.
https://github.com/jgm/pandoc/discussions/

pandoc,
@pandoc@fosstodon.org avatar

@amoroso Thank you, I'll forward this information to John, who's the list maintainer.

pandoc,
@pandoc@fosstodon.org avatar

@leah managed to restore most pandoc-discuss mails and made them available at https://inbox.vuxu.org/pandoc-discuss.
Thank you, Leah!

  • All
  • Subscribed
  • Moderated
  • Favorites
  • provamag3
  • InstantRegret
  • mdbf
  • ethstaker
  • magazineikmin
  • GTA5RPClips
  • rosin
  • thenastyranch
  • Youngstown
  • osvaldo12
  • slotface
  • khanakhh
  • kavyap
  • DreamBathrooms
  • JUstTest
  • Durango
  • everett
  • cisconetworking
  • Leos
  • normalnudes
  • cubers
  • modclub
  • ngwrru68w68
  • tacticalgear
  • megavids
  • anitta
  • tester
  • lostlight
  • All magazines