Open arokettu opened 1 year ago
Not necessarily. You just need asciidoc
or asciidoctor
in your PATH
. It can point to your local install or a shell wrapper script.
Or a bit hacky but you can even do:
from pelican_plugins import asciidoc_reader # adjust import accordingly
ASCIIDOC_CMD = "your command here"
asciidoc_reader.ALLOWED_CMDS.append(ASCIIDOC_CMD)
# ...
PLUGINS = [asciidoc_reader, ...]
Yes, it works with bundle exec pelican
in my case but the limitation seems arbitrary. I would understand it if there was some logic that depended on the tool being used but I see none
I could agree. I'm happy to review a PR if you want to submit one :).
Whitelisting possible commands prevents use of locally installed parsers like
bin/asciidoc
orbundle exec asciidoctor