tags:

views:

34

answers:

2

Is it possible to publish your site reports to github? For instance, I run Checkstyle, Findbugs, Cross Reference, and other plugins and would like to have that publicly available. Since my project is already there, I'd like to just keep it there.

A: 

With the state of the plugins that exist now, you'd have to do some shimming. The site command (per your comments: wanting to use mvn:site) has a mechanism (stage) for pushing the resulting site somewhere, but it's all mostly predicated on SCP'ing it around to some final destination. For github, I don't think there's any obvious place to land things like that.

The solution would be to write something that extended the site plugin to check in the results to Github using the github pages functionality. Details on the github pages bits are available at http://pages.github.com/. To get there, you'll be writing something that checks in your resulting site to a root branch "gh-pages" and going from there.

heckj
I came across that yesterday and was thinking that I could copy the site directory to a branch that it suggests. It would be under version control so I would have a record. I think this is probably what I will do.
I attempted to do this a while back. It wasn't 100% successful, but it seemed to work OK.http://happygiraffe.net/blog/2009/01/17/github-pages-with-maven/
Dominic Mitchell
If I get time, would you want to start an open source github maven plugin that does exactly that? I am not too concerned with site reports since it is only me presently.
A: 

The Maven way to publish your reports would be to build the Maven site and to deploy it using FTP, SCP or DAV.

I don't know if GitHub provides hosting space and supports any of this protocol. If it does, then the following resources will help:

If it doesn't, better look for another place to host your site.

Pascal Thivent