diff options
author | Andrew Tridgell <tridge@samba.org> | 2010-09-25 15:53:32 -0700 |
---|---|---|
committer | Andrew Tridgell <tridge@samba.org> | 2010-09-26 01:21:49 +0000 |
commit | 5d5ae099d16d1902e4a85adec5b1e6a9085b6118 (patch) | |
tree | 83492e45dc8e185dde9afa951650d859dfe6cb5b | |
parent | 91b62a274411477f67f50f0f653dd17bf1e65c1d (diff) | |
download | samba-5d5ae099d16d1902e4a85adec5b1e6a9085b6118.tar.gz samba-5d5ae099d16d1902e4a85adec5b1e6a9085b6118.tar.xz samba-5d5ae099d16d1902e4a85adec5b1e6a9085b6118.zip |
autobuild: added --rebase-master and --push-master
Pair-Programmed-With: Stefan Metzmacher <metze@samba.org>
-rwxr-xr-x | script/autobuild.py | 24 | ||||
-rwxr-xr-x | script/commit_mark.sh | 5 |
2 files changed, 26 insertions, 3 deletions
diff --git a/script/autobuild.py b/script/autobuild.py index 4a10092bced..a1b45906a95 100755 --- a/script/autobuild.py +++ b/script/autobuild.py @@ -8,43 +8,53 @@ import os, signal, tarfile, sys, time from optparse import OptionParser +samba_master = os.getenv('SAMBA_MASTER', 'git://git.samba.org/samba.git') +samba_master_ssh = os.getenv('SAMBA_MASTER_SSH', 'git+ssh://git.samba.org/data/git/samba.git') + cleanup_list = [] tasks = { "source3" : [ "./autogen.sh", "./configure.developer ${PREFIX}", "make basics", - "make -j", - "make test" ], + "make -j 4 everything", # don't use too many processes + "make install", + "TDB_NO_FSYNC=1 make test" ], "source4" : [ "./autogen.sh", "./configure.developer ${PREFIX}", "make -j", - "make test" ], + "make install", + "TDB_NO_FSYNC=1 make test" ], "source4/lib/ldb" : [ "./autogen-waf.sh", "./configure --enable-developer -C ${PREFIX}", "make -j", + "make install", "make test" ], "lib/tdb" : [ "./autogen-waf.sh", "./configure --enable-developer -C ${PREFIX}", "make -j", + "make install", "make test" ], "lib/talloc" : [ "./autogen-waf.sh", "./configure --enable-developer -C ${PREFIX}", "make -j", + "make install", "make test" ], "lib/replace" : [ "./autogen-waf.sh", "./configure --enable-developer -C ${PREFIX}", "make -j", + "make install", "make test" ], "lib/tevent" : [ "./autogen-waf.sh", "./configure --enable-developer -C ${PREFIX}", "make -j", + "make install", "make test" ], } @@ -226,8 +236,12 @@ parser.add_option("", "--verbose", help="show all commands as they are run", default=False, action="store_true") parser.add_option("", "--rebase", help="rebase on the given tree before testing", default=None, type='str') +parser.add_option("", "--rebase-master", help="rebase on %s before testing" % samba_master, + default=False, action='store_true') parser.add_option("", "--pushto", help="push to a git url on success", default=None, type='str') +parser.add_option("", "--push-master", help="push to %s on success" % samba_master_ssh, + default=False, action='store_true') parser.add_option("", "--mark", help="add a Tested-By signoff before pushing", default=False, action="store_true") @@ -258,6 +272,8 @@ except: try: if options.rebase is not None: rebase_tree(options.rebase) + elif options.rebase_master: + rebase_tree(samba_master) blist = buildlist(tasks, args) if options.tail: blist.start_tail() @@ -278,6 +294,8 @@ if status == 0: run_cmd(options.passcmd, dir=test_master) if options.pushto is not None: push_to(options.pushto) + elif options.push_master: + push_to(samba_master_ssh) if options.keeplogs: blist.tarlogs("logs.tar.gz") print("Logs in logs.tar.gz") diff --git a/script/commit_mark.sh b/script/commit_mark.sh index 38328c48271..bb1e9428a04 100755 --- a/script/commit_mark.sh +++ b/script/commit_mark.sh @@ -1,6 +1,11 @@ #!/bin/sh # add a autobuild message to the HEAD commit +if grep -q '^Autobuild.User' "$1"; then + echo "Already marked as tested" + exit 0 +fi + fullname=$(getent passwd $USER | cut -d: -f5| cut -d',' -f1) cat <<EOF >> "$1" Autobuild-User: $fullname <$USER@samba.org> |