To: cruisecontrol-devel@lists.sourceforge.net From: Pete Doyle Date: Mon, 14 Apr 2008 18:17:06 +0000 (UTC) Message-ID: Subject: [Cruisecontrol-devel] First attempt at fixing Ant Output widget (2.7.2) Hi CC Devs, I've been setting up a new CC install where I work and have been trying to get the new Ant Output widget working. After struggling with it (it displays "No information for Ant Output"), I was able to take a look at the code and get it working (see patches at the end). There are two main issues keeping it from working in 2.7.2. First, Widget.PARAM_CC_ROOT doesn't seem to be available to Widget plugins. (Which might already be known since the API is deprecated now). I hard-coded it for now in WidgetPluginService.java to "c:\program files\cruisecontrol", but am hoping you guys might know a good place to pull it from. Second, the casts to type File for the ccRoot and xsl variables in AbstractXslOutputWidget.java were generating ClassCastException's, so I changed the casts to use "new File(...)" instead of casting to type File. Also, there's a much improved ant.xsl file which makes it more appropriate to be embedded inside an existing page (remove the generated HTML, BODY tags and change the CSS to apply only to the Ant output, instead of to the entire BODY). Without these changes, the output was severely affecting how the dashboard itself looked - changing the dashboard fonts, colors, etc. I'm hoping the patches come through OK below, but if not, let me know and I can email them. Thanks, Pete Doyle petedoyle@gmail.com patch: http://pastebin.ca/984989 screenshot: http://imagebin.ca/view/1bq2WI.html