todo-to-issue-action icon indicating copy to clipboard operation
todo-to-issue-action copied to clipboard

Handle comment delimiters not on same line as 'todo' keyword

Open klein0r opened this issue 2 years ago • 3 comments

Comments are defined like this:

..
    _This: is a comment!

..
    [and] this!

..
    this:: too!

..
    |even| this:: !

Additionally, support for https://www.sphinx-doc.org/en/master/usage/extensions/todo.html would be awesome

.. todo::
     This is a todo

klein0r avatar Jun 08 '22 15:06 klein0r

Interesting, thanks for the suggestion! It would definitely be good to add this; PR requests are always welcome for new languages, and they're relatively easy to do. This does look a little more complicated than the standard comment syntax. For one, at the moment if the comment delimiter is not on the same line as the 'todo' keyword/title, it won't get picked up, but that is something I am hoping to improve.

alstr avatar Jun 10 '22 08:06 alstr

I've done some experimentation and the challenges to adding this at the moment are:

  • [x] The lowercase todo (added support in latest commit)
  • [ ] The double colon after todo (at the moment it thinks the second colon is the title)
  • [ ] The fact that the formatting is somewhat unique; it isn't like a normal line comment as there is no comment delimiter on the second line, but it isn't a block comment as there's no closing tag.

The second one is an easy fix; the third is a bit more involved.

alstr avatar Aug 23 '22 14:08 alstr

We'd surely be a bunch to welcome this addition! Thanks for taking care of it :)

silopolis avatar Feb 08 '23 10:02 silopolis