[Buildbot-devel] authenicated SVN checkouts..
Charles Hardin
chardin at 2wire.com
Wed Jun 28 14:45:46 UTC 2006
When passing the username and password, you might want to consider adding a patch that doesn't display the full command line arguements on the status page...
The following patch is part of a more complex custom patch, so I just included the parts for the header display - this hasn't been tested as a standalone patch, so apologize if it doesn't work correctly, but hopefully can be used as a base if you want to hide the headers...
diff -Nuar buildbot-0.7.2-orig/buildbot/process/step.py buildbot-0.7.2-p4/buildbot/process/step.py
--- buildbot-0.7.2-orig/buildbot/process/step.py 2006-06-19 15:18:26.000000000 -0700
+++ buildbot-0.7.2-p4/buildbot/process/step.py 2006-06-19 14:59:51.000000000 -0700
@@ -1,6 +1,7 @@
# -*- test-case-name: buildbot.test.test_steps -*-
import time, random, types, re, warnings
+from types import ListType, StringType
from email.Utils import formatdate
from twisted.internet import reactor, defer, error
@@ -267,6 +268,10 @@
if update.has_key('stderr'):
self.addStderr(update['stderr'])
if update.has_key('header'):
+ if self.args.has_key('display'):
+ if self.args['display'] is False:
+ log.msg("Filtered header: %s" % update['header'])
+ return
self.addHeader(update['header'])
if update.has_key('rc'):
rc = self.rc = update['rc']
@@ -290,7 +295,7 @@
def __init__(self, workdir, command, env=None,
want_stdout=1, want_stderr=1,
- timeout=20*60, **kwargs):
+ timeout=20*60, display=True, **kwargs):
"""
@type workdir: string
@param workdir: directory where the command ought to run,
@@ -341,11 +346,19 @@
'want_stdout': want_stdout,
'want_stderr': want_stderr,
'timeout': timeout,
+ 'display': display,
}
LoggedRemoteCommand.__init__(self, "shell", args)
def start(self):
@@ -691,6 +704,7 @@
descriptionDone = None # alternate description when the step is complete
command = None # set this to a command, or set in kwargs
progressMetrics = ['output']
+ display = True
parms = BuildStep.parms + [
'description',
diff -Nuar buildbot-0.7.2-orig/buildbot/test/test_steps.py buildbot-0.7.2-p4/buildbot/test/test_steps.py
--- buildbot-0.7.2-orig/buildbot/test/test_steps.py 2005-10-26 13:22:50.000000000 -0700
+++ buildbot-0.7.2-p4/buildbot/test/test_steps.py 2006-06-19 15:13:34.000000000 -0700
@@ -114,12 +114,17 @@
expectedEvents.append(["callRemote", "startCommand",
(rc, "3",
"shell",
- {'command': "argle bargle",
- 'workdir': "murkle",
- 'want_stdout': 1,
- 'want_stderr': 1,
- 'timeout': 10,
- 'env': None}) ] )
+ {'display': True,
+ 'command': "argle bargle",
+ 'workdir': "murkle",
+ 'want_stdout': 1,
+ 'want_stderr': 1,
+ 'timeout': 10,
+ 'env': None}) ] )
self.assertEqual(self.remote.events, expectedEvents)
# we could do self.remote.deferred.errback(UnknownCommand) here. We
-----Original Message-----
From: buildbot-devel-bounces at lists.sourceforge.net on behalf of Julien Gilli
Sent: Wed 6/28/2006 7:27 AM
To: Michael March
Cc: buildbot-devel at lists.sourceforge.net
Subject: Re: [Buildbot-devel] authenicated SVN checkouts..
Hello,
On 6/28/06, Michael March <mmarch at gmail.com> wrote:
>
> I (and I think this list) would *love* to see the patch.
>
> Here it is. It should apply on buildbot 0.7.3 fine. It may contains some
indentations issues, and it has been generated on Windows. Please, let me
know if you need anymore information.
Best regards,
--
Julien Gilli
More information about the devel
mailing list