[Buildbot-devel] file upload code

Dustin J. Mitchell dustin at zmanda.com
Mon Jun 30 16:54:57 UTC 2008


On Mon, Jun 30, 2008 at 12:22 PM, Bailey, Darragh <dbailey at hp.com> wrote:
> What I'm not clear about is how exactly I should be feeding the output of the RemoteShellCommand into a setProperty function call and use that to set the name of the file to retrieve.

There's a SetProperty step that can do this:

@bsindex buildbot.steps.shell.SetProperty

This buildstep is similar to ShellCommand, except that it captures the
output of the command into a property.  It is usually used like this:

@example
f.addStep(SetProperty(command="uname -a", property="uname"))
@end example

This runs @code{uname -a} and captures its stdout, stripped of leading
and trailing whitespace, in the property "uname".  To avoid stripping,
add @code{strip=False}.  The @code{property} argument can be specified
as a @code{WithProperties} object.


Then you can just use a WithProperties object in your FileUpload script.

Dustin

-- 
Storage Software Engineer
http://www.zmanda.com




More information about the devel mailing list