org-sync icon indicating copy to clipboard operation
org-sync copied to clipboard

Add support for syncing issue comments

Open plajjan opened this issue 7 years ago • 0 comments

org-sync currently only supports syncing the issue itself and whatever properties it might have. Comments on the issue however, are not synced. Clearly, this would be a very nice feature to have.

I am not super intimate with the core of org-sync but I imagine quite a bit of work needs to happen there after which we can add support in the various backends. Comments are conceptually a little different from issues. Issues have a title which is natural to use as the org mode header. Comments do not have a title, so what do we put as the header?

Looking at the org format I think it would be nice with just another sub-header under which the comments are so that it's easy to fold. Here we use the timestamp as the header.

* OPEN Add support for syncing issue comments
:PROPERTIES:
...stuff..
:END:
** Comments
*** 2018-02-12 13:29:14
:PROPERTIES:
:id:  12
:END:
This is the first comment on this issue
*** 2018-02-12 13:30:86
:PROPERTIES:
:id:  13
:END:
This is the second comment.

Another way would be to skip trying to use the timestamp as a title and just start with the comments first line as the header, like this:

* OPEN Add support for syncing issue comments
:PROPERTIES:
...stuff..
:END:
** Comments
*** This is the first comment on this issue
:PROPERTIES:
:id:  12
:END:
*** This is the second comment
:PROPERTIES:
:id:  13
:END:

This probably works great for single line comments but might look bad with multi-line?

We could also remote the Comments sub-header and place the comments directly under the issue but I'm afraid it would turn chaotic quickly.

Comments should be sorted by date so we can expect the order to be updated by org-sync and any other order that the user tries to use will be overwritten. It should be possible to add a comment at the end by creating a new sub-header and sync. It should also be possible to edit a comment (if the backend allows for it). Not sure about deleting comments!?

Other ideas? thoughts?

plajjan avatar Feb 12 '18 12:02 plajjan