NAnt.ToDo a NAnt Plugin
This simple plugin for NAnt parses your source code and creates a report of all the TODO and comment tags in your source code. The code is hosted over at google code.
Comments
The task automatically identify comments in the following style
//TODO: First Test to do Item //FIXME: First Fix me Item //HACK: First Hack Item
Additional matches can be made by adding in Token elements to the NAnt task.
Sample
<ToDo source="path/to/source" output="report.xml" searchpattern="*.cs;*.txt"> <Tokens> <Tokens Value="BUGFIX" /> </Tokens> </ToDo>
Output
<ToDo xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema"> <Items> <Item> <Message>First Test to do Item</Message> <File>NAnt.ToDo\ToDoTask.cs</File> <Line>0</Line> <Type>TODO</Type> </Item> <Item> <Message>First Hack Item</Message> <File>NAnt.ToDo\ToDoTask.cs</File> <Line>0</Line> <Type>HACK</Type> </Item> <Item> <Message>First Fix me Item</Message> <File>NAnt.ToDo\ToDoTask.cs</File> <Line>0</Line> <Type>FIXME</Type> </Item> </Items> </ToDo>
Cruise Control Xsl
Below is a basic xsl style sheet that can be used with CruiseControl.NET to display the output from NAnt.ToDo.
<?xml version="1.0"?> <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"> <xsl:output method="html"/> <xsl:param name="applicationPath"/> <xsl:template match="/"> <div id="ToDo"> <h1>ToDo List</h1> <div id="Summary"> <h3>To Do</h3> <table> <tbody> <xsl:for-each select="//ToDo/Items/Item"> <tr> <td> <xsl:value-of select="Type/text()"/> </td> <td> <xsl:value-of select="Message/text()"/> </td> <td> <xsl:value-of select="File/text()"/> </td> </tr> </xsl:for-each> </tbody> </table> </div> </div> </xsl:template> </xsl:stylesheet>








Daniel Hommel 7:59 pm on April 10, 2009 Permalink |
I tried to make CCTray work on mono once and i had to comment out a lot of stuff to get it kind of working (all the windows-isms had to go)… After i got it running there were still a bunch of problems, like a ghost window with no content behind the CCTray window, all the projects showing up 2 times and the tray icon also didn’t work as it should. After all i think writing a Gtk# client is a good idea. I hope you will publish the code soon so i can try it out in my GNOME environment. BTW, do you use CCTrayLib for that project?
regards,
Daniel
Daniel Hommel 8:03 pm on April 10, 2009 Permalink |
Just found out that you did publish the code already and that also answered my question about CCTrayLib. I’ll try it out and let you know how it work.
regards,
Daniel