Link to mylyn task in Java comment (Eclipse)

佐手、 提交于 2019-12-13 01:31:53

问题


I have just started using Eclipse and Mylyn together, so I'm quite new to the workflow and how the tools and their features are intended to be used together.

Quite frequently I find myself wanting to write a comment in the code, usually a // TODO or similar remark, and reference a ticket in the Trac repository I've hooked myself up to via Mylyn. Currently, I just lookup the ticket number and write something like // FIXME: bug here, see ticket #18 in the comment.

Is there a way to make that link clickable, so that I can just click in the comment when I find one and it opens the ticket in Mylyn? And vice versa, is there a way to configure Mylyn so that when viewing a ticket I can see all comments referencing it?


回答1:


Hyperlinks in comments should be available with the following patterns as long as you have a Trac repository defined in your Task Repositories view:

  • ticket:128
  • #512

You can see the regular expression used here.

You can link a project to a specific Trac repository from the project's Task Repository property page available from the Properties menu.



来源:https://stackoverflow.com/questions/8720206/link-to-mylyn-task-in-java-comment-eclipse

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!