codesoap / jirae

jirae allows you to edit texts in Jira with your local editor instead of Atlassian's WYSIWYG editor
MIT License
3 stars 0 forks source link

support comment URLs #3

Closed tbussmann closed 1 year ago

tbussmann commented 1 year ago

A handy alternative over specifying ISSUE_NUMBER and COMMENT_ID as commandline parameters would be to allow passing a Issue/Comment URL. The latter have the format https://somecorp.atlassian.net/browse/SCO-1234?focusedCommentId=4321 and can be copied by clicking the little anchor icons in the issue view. Parsing them should not be to hard and can be done in a wrapper script or directly within jirae (sorry, no PR as I know hardly any go)

codesoap commented 1 year ago

Good idea, I didn't think of that. I think I'll include it in jirae itself. Maybe I could even read the URL from the clipboard, so that the user doesn't even have to paste it.

I'll try to implement it within the next few days.

codesoap commented 1 year ago

The more I think about it, the more sense URLs make to me. Maybe I'll change the interface and only support URLs. The issue URL would then make jirae edit the description (see #1) and comment URLs would make jirae edit a comment. With this, I can further simplify the tool by dropping the need for the JIRA_URL environment variable.

Thanks again for sharing your idea! Sometimes I just don't see the obvious solutions.

codesoap commented 1 year ago

I have implemented the change now: https://github.com/codesoap/jirae/commit/7e691e98c9267eed214021b79f8f1569cb0c591c