Skip to content

Latest commit

 

History

History
26 lines (15 loc) · 1.5 KB

README.md

File metadata and controls

26 lines (15 loc) · 1.5 KB

PanTidDoc

Convert virtually any file (including PDFs) to a tiddler--edit it, search it, quote it, transclude it.

Description

I frequently encounter files that I want to include in my personal wiki. TiddlyWiki can embed files, but you can't really do anything with them. I wanted a way to transform my files into tiddlers to be able to utilize all the great features of TiddlyWiki.

This script is my solution. First, the script checks if the input file is a PDF (RunMe.sh). Because Pandoc cannot convert PDFs, the PDF is converted to HTML by pdf2htmlEX (RunMe.sh). The resulting file (or the original file, if not a PDF) is then converted to WikiText through a custom writer for Pandoc (wikitext.lua). Finally, the WikiText is cleaned up and encoded for proper importing into TiddlyWiki (tiddlify.py).

Requirements

Usage

./RunMe.sh filename.ext

Contributing

If you have found a bug or have suggestions for improvements, please open an issue. Feel free to fork this repository and hack it however you wish. PanTidDoc is a work in progress, and thus very far from perfect.