Bug 210590 - Make it possible to add TODOs to Task list
Make it possible to add TODOs to Task list
Status: REOPENED
Product: platform
Classification: Unclassified
Component: Action Items
7.2
PC Windows XP
: P3 (vote)
: TBD
Assigned To: Jan Peska
issues@platform
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2012-04-03 06:32 UTC by Peter Nabbefeld
Modified: 2013-02-12 14:54 UTC (History)
0 users

See Also:
Issue Type: ENHANCEMENT
:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Peter Nabbefeld 2012-04-03 06:32:12 UTC
E.g. use comments like this:
<!-- TODO: This template is currently buggy -->
Comment 1 Svata Dedic 2012-05-17 11:22:45 UTC
This should be already possible; see Tools | Options | Misc | Action items for recognized patterns.
Comment 2 Peter Nabbefeld 2012-05-17 12:46:19 UTC
(In reply to comment #1)
> This should be already possible; see Tools | Options | Misc | Action items for
> recognized patterns.

You seem to miss sth.:
It's not by accident, that I used category "xml/XML Multiview" to report the issue. TODOs are working fine for me in Java, but they don't work for me with XML and XSL files. If I'm just missing sth., please tell me, but it just seems there's no tasklist provider for those files.

I had a look at TodoTaskScanner.java, finding these lines:
   181     private List<? extends Task> scanComments( FileObject resource ) {
   182         String ext = resource.getExt().toLowerCase();
   183         String mime = FileUtil.getMIMEType( resource );
   184 
   185         String lineComment = Settings.getDefault().getLineComment( ext, mime );
   186         String blockCommentStart = Settings.getDefault().getBlockCommentStart( ext, mime );
   187         String blockCommentEnd = Settings.getDefault().getBlockCommentEnd( ext, mime );

How can I find out, what is returned for XML files (which would be a necessary clue to find out what the code does, so I could probably understand what isn't working)?
Comment 3 Svata Dedic 2012-05-17 13:20:40 UTC
Good point; I reacted on the 'XML', so I've tested the TODOs on XMLs only - on the 'plain' XML, not on any more specific mimetype. Sorry.

It seems that the list file extensions + mimetypes supported by task scan is hardcode in the org.netbeans.modules.tasklist.todo.settings.Settings class.

Maybe support for MIME inheritance (e.g. text/xsl+xml => text/xml) could be supported as well.

Moving to tasklist/action items support.
Comment 4 Jan Peska 2013-02-12 14:54:28 UTC
fix: http://hg.netbeans.org/core-main/rev/6bce001495c4

user can manages supported file extensions and MIME types of TODO scanner via Tools/Option/Miscellaneous/Action Items


By use of this website, you agree to the NetBeans Policies and Terms of Use. © 2012, Oracle Corporation and/or its affiliates. Sponsored by Oracle logo