From 69d077f81fd00cb9b462030ffb6b8cc8cd9b25c4 Mon Sep 17 00:00:00 2001 From: Daniel Narvaez Date: Tue, 25 Dec 2012 18:20:39 +0000 Subject: Merge branch 'testing' --- (limited to 'commands') diff --git a/commands/build b/commands/build index 6911394..714e783 100755 --- a/commands/build +++ b/commands/build @@ -5,18 +5,23 @@ import sys import common +from devbot import system from devbot import build parser = argparse.ArgumentParser() parser.add_argument("module", nargs="?", help="name of the module to build") +parser.add_argument("--full", action="store_true", help="force a full build") args = parser.parse_args() common.setup() +if not system.check(skip_if_unchanged=True): + sys.exit(1) + if args.module: success = build.build_one(args.module) else: - success = build.build() + success = build.build(full=args.full) if not success: sys.exit(1) diff --git a/commands/check-system b/commands/check-system index 1bfb3e6..f610bcb 100755 --- a/commands/check-system +++ b/commands/check-system @@ -1,6 +1,7 @@ #!/usr/bin/python -u import argparse +import sys import os import common @@ -16,14 +17,12 @@ parser.add_argument("--remove", action="store_true", help="remove all the unnecessary packages") parser.add_argument("--test", action="store_true", help="don't add or remove packages, test only") -parser.add_argument("--skip-if-unchanged", action="store_true", - help="skip if unchanged from the last check") args = parser.parse_args() interactive = "SUGAR_BUILDBOT" not in os.environ -system.check(update=args.update, - remove=args.remove, - test=args.test, - interactive=interactive, - skip_if_unchanged=args.skip_if_unchanged) +if not system.check(update=args.update, + remove=args.remove, + test=args.test, + interactive=interactive): + sys.exit(1) diff --git a/commands/common.py b/commands/common.py index 80c42b4..61d9537 100644 --- a/commands/common.py +++ b/commands/common.py @@ -7,8 +7,11 @@ sys.path.append(base_dir) from devbot import config from devbot import command +from devbot import git def setup(): + git.set_root_path(base_dir) + args = {"config_dir": os.path.join(base_dir, "config"), "install_dir": os.path.join(base_dir, "install"), "source_dir": os.path.join(base_dir, "source"), -- cgit v0.9.1