diff options
Diffstat (limited to 'commands')
-rwxr-xr-x | commands/build | 2 | ||||
-rw-r--r-- | commands/common.py | 8 | ||||
-rwxr-xr-x | commands/pull | 2 |
3 files changed, 6 insertions, 6 deletions
diff --git a/commands/build b/commands/build index 0a8b2d4..38cae6b 100755 --- a/commands/build +++ b/commands/build @@ -13,7 +13,7 @@ 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() +common.setup(log_name="build") if not system.check(skip_if_unchanged=True): sys.exit(1) diff --git a/commands/common.py b/commands/common.py index e92f798..ac39daf 100644 --- a/commands/common.py +++ b/commands/common.py @@ -10,7 +10,7 @@ from devbot import command from devbot import git -def setup(): +def setup(log_name=None): git.set_root_path(base_dir) args = {"config_dir": os.path.join(base_dir, "config"), @@ -21,10 +21,10 @@ def setup(): "prefs_path": os.path.join(base_dir, "prefs"), "logs_dir": os.path.join(base_dir, "logs")} + if log_name: + args["log_name"] = log_name + if "SUGAR_BUILDBOT" in os.environ: args["relocatable"] = True config.setup(**args) - - tools_dir = os.path.join(base_dir, "tools") - command.set_logger(os.path.join(tools_dir, "log-command")) diff --git a/commands/pull b/commands/pull index 5989be6..cca1ff2 100755 --- a/commands/pull +++ b/commands/pull @@ -11,7 +11,7 @@ parser = argparse.ArgumentParser() parser.add_argument("module", nargs="?", help="name of the module to pull") args = parser.parse_args() -common.setup() +common.setup(log_name="pull") if args.module: success = build.pull_one(args.module) |