retext-project / retext

ReText: Simple but powerful editor for Markdown and reStructuredText
GNU General Public License v2.0
1.88k stars 196 forks source link

Help setting up markdown-checklist extension #361

Closed nodiscc closed 6 years ago

nodiscc commented 6 years ago

Hi, I am trying to enable https://github.com/FND/markdown-checklist in Retext to add support for checkboxes (- [ ] and - [x]). I have installed the extension using pip install markdown-checklist --user and it installs properly in ~/.local/lib/python2.7/site-packages/markdown_checklist/, I can import markdown_checklist from the Python console without errors.

I have added markdown_checklist to the list of extensions in ~/.config/markdown-extensions.txt and/or through Retext's extensions field in the settings dialog.

However no checkboxes are rendered.

How should I proceed to add this extension to Retext?

retext 7.0.1-1, Debian 9 stretch

Thanks in advance

mitya57 commented 6 years ago

ReText uses Python 3, not Python 2.7. So you need to replace pip with pip3 in your command.

Also, the extension name should be markdown_checklist.extension, not just markdown_checklist according to its documentation.

After changing that, it works fine for me: Screenshot

See https://github.com/retext-project/retext/issues/243#issuecomment-249485790 for the instructions to install a different extension for the same task, maybe it looks a bit nicer.

nodiscc commented 6 years ago

Thanks, and great suggestion! I installed https://facelessuser.github.io/pymdown-extensions/ using pip3 install --user pymdown-extensions and added pymdownx.tasklist to ~/.config/markdown-extensions.txt.