views:

35

answers:

1

We're considering moving to Hudson, and currently have build steps that write 2 files (say, a log file and an audit file), and I would like both of them to be viewable for each step (kind of like the Console Output thing, simply for other files).

I couldn't find a plugin that seemed to do this from the short descriptions. What's the way for doing this in Hudson?

+1  A: 

If it is ok to put them in the output than you can simply add another build step that prints these files to the output (use cat (linux/unix) or type (windows)).

EDIT I just a new idea.

Use the archive feature of your job for the two files. They will appear as build artifacts on the status page of the job, if you click on the link you can see them in the browser. That should solve your problem.

Peter Schuetze
Given that steps don't have names, adding 2 more steps per build step (and we have about 10 actual build steps) sounds like too much, and quite cluttered. Thanks for the idea though!
abyx
It is just one build step, you can write whole scripts in the 'Execute Windows batch command' or 'execute shell' build steps. Hudson will create a temporary file to execute it. You can also add comments or echos to do that. Have a look at the Log Parser plugin (http://wiki.hudson-ci.org//display/HUDSON/Log+Parser+Plugin) to make your output more readable.
Peter Schuetze
@abyx, 10 build steps sounds like something that should be refactored into a build script instead of just stored in Hudson (or whatever CI system).
Dave Bacher
@Dave Imagine a framework with 10 sub modules. We like to run each one's tests in a different step, so team members can recognize quickly who broke the build.
abyx
Are you talking about different build steps or different jobs?
Peter Schuetze
Go with the build script and mark the beginnings of each section with a unique string. Than you can use the log parser plugin (http://wiki.hudson-ci.org//display/HUDSON/Log+Parser+Plugin). Define a rule for the info category to find the unique strings for the sections and the plugin will organize the rest for you. Disclaimer: I havn't used that plugin yet, but plan to test it soon.
Peter Schuetze