Pandoc in Termux - jgm/pandoc GitHub Wiki
Pandoc’s precompiled, static ARM binary works with Termux the terminal emulator app for Android:
To make pandoc available in Termux follow the steps below.
- 
Create the directory ${HOME}/binand put it in yourPATHif you haven’t done so already.
- 
Download the ARM .tar.gzarchive from Pandoc’s release page.
- 
Unpack the archive. ( tar -xzvf <archive>)
- 
cdto thebinsubdirectory in the unpacked directory.
- 
mvorcpthepandocbinary to${HOME}/bin(mv pandoc ${HOME}/bin).
- 
Do cd ${HOME}/bin
- 
Make sure pandocis executable (chmod +x pandoc).
- 
WARNING! Pandoc’s interactive Lua mode doesn’t work in Termux. It hangs the session and the only way out is to kill Termux in Android’s Settings/Apps interface. pandoc lua <filename>works fine!
- 
You may want to define an environment variable with the path to the default Pandoc data directory..In my ~/.zshenvfile I haveexport PDC_DATA_DIR="$HOME/.local/share/pandoc"; others may want to put it in~/.bashrc. Don’t forget tomkdir -p $HOME/.local/share/pandoc/filtersetc.
- 
You may not want to install LaTeX support which requires some huge packages. IMO the best way to produce PDF with Pandoc in Termux is html/weasyprint. There is no Termux package for weasyprint so you will have to install Python 3 and [other dependencies][] and install it with pip.install weasyprint.
- 
If you are using filters - You may want to make sure luarocksis installed.
- You want to set your LUA_PATHvariable properly.
- External C libraries don’t work with Lua via the static pandoc binary. The helper modules included with pandoc are pretty comprehensive though, and pipes work fine, so you may be able to work around some limitations with external tools and scripts. Note in particular that you can create and pass around JSON to/from external scripts.
 
- You may want to make sure