Christoph Torens edited a comment on Bug JENKINS-15438

i had to do the following edits to get it working

plugins\violations\model\BuildModel.java (line 144...)
    private FileModelProxy  getFileNameProxy(String name) {
        FileModelProxy proxy = fileModelMap.get(name);
        if (proxy != null) {
            return proxy;
        }
        File xmlFile = new File(
            xmlRoot, "file/" + name + ".xml");
        fileModelMap.put(name, new FileModelProxy(xmlFile));
+        proxy = fileModelMap.get(name);
        return proxy;
    }

    /**
     * Add a file count.
     * @param type the type.
     * @param name the filename.
     * @param count the number of violations.
     */
    public void addFileCount(String type, String name, int[] count) {
+    	// windows needs this replacement
+        name = name.replace("\\", "/");
        FileModelProxy proxy = getFileNameProxy(name);
        getFileCounts(type).add(new FileCount(name, count, proxy));
    }

– plugins\violations\ViolationsReport.java (lin 240...)

return new RecurDynamic(
-               "", name, proxy.build(build).contextPath(req.contextPath()));
+            	"", name, proxy.build(build).contextPath(""));
        } else {

sorry cant do a proper diff right now
hope that hlps others...

This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators.
For more information on JIRA, see: http://www.atlassian.com/software/jira

Reply via email to