Hi all,

I am using Pandoc (by way of a Perl script called from within TextWrangler on Mac OS 10.6.8) to publish my amateurish scribblings to a variety of fan fiction repositories on the Web. All of them bar my own personal site use an extremely crippled subset of HTML with no stylesheet support as an input format, and just to make things extra fun, the nature of the HTML crippling varies from repository to repository. This is easily gotten around in theory by making a custom writer for each repository, but the first one I tried (for fanfiction.net) is giving me serious and intractable problems.

First was the fact that nowhere is it apparently documented what directory the “-t path/to/custom_writer.lua” is relative to (it definitely isn’t the same directory the “templates” folder lives in), and using “~” as an abbreviation for my home directory is apparently not supported. I finally got around that one by specifying an absolute path from the root of my filesystem, which seems unnecessarily fragile and inflexible.

Second, when I FINALLY got the damn thing to actually try to call the custom writer, it immediately bombed out with the following error message:

>
> PANIC: unprotected error in call to Lua API (attempt to call a string value)
>

This is… less than informative. Does anyone have any idea what’s going on here? I went over my modifications to the sample.lua file and I can’t find anything very different from what was supplied initially—my changes were almost all cosmetic, of the “turn an insertion of unsupported HTML tag X into an insertion of <p> (or <b>, or whatever)” variety. In the absence of more helpful diagnostic messages, I am completely at a loss for how to proceed.

--
You received this message because you are subscribed to the Google Groups "pandoc-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org.
To post to this group, send email to pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org.
To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/fc67fe32-8b42-4ba3-9ef5-a072a47fd8d9%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.