diff options
author | kennyballou <kballou@onyx.boisestate.edu> | 2013-03-07 18:51:07 -0700 |
---|---|---|
committer | kennyballou <kballou@onyx.boisestate.edu> | 2013-03-07 18:51:07 -0700 |
commit | 76d0ba3ae1f76900d4f802a7e37ca527a832dfba (patch) | |
tree | 623a145915c9c67b5723211b1b3d18bd3b72f05d | |
parent | e58f93d435b7a4bb3682ea17086a48a8ab065389 (diff) | |
download | xnt-76d0ba3ae1f76900d4f802a7e37ca527a832dfba.tar.gz xnt-76d0ba3ae1f76900d4f802a7e37ca527a832dfba.tar.xz |
Refactor xnt.tasks.xnt
Rename function to xntcall -- Fixes clobbering issues
Update parameters to align with the target runner parameters
Update doctstring
-rw-r--r-- | xnt/tasks.py | 15 |
1 files changed, 9 insertions, 6 deletions
diff --git a/xnt/tasks.py b/xnt/tasks.py index 22df254..00e562a 100644 --- a/xnt/tasks.py +++ b/xnt/tasks.py @@ -101,14 +101,17 @@ def echo(msg, tofile): def log(msg="",lvl=logging.INFO): logger.log(lvl, msg) -def xnt(target, path): - """ - Invoke xnt on another build file in a different directory +def xntcall(path, targets=None, props=None): + """Invoke xnt on another build file in a different directory + + param: path - to the build file (including build file) + param: targets - list of targets to execute + param: props - dictionary of properties to pass to the build module """ import xnt.xenant - xnt.xenant.invokeBuild( - xnt.xenant.__loadBuild(path), - target) + from xnt.commands.target import TargetCommand + command = TargetCommand(xnt.xenant.loadBuild(path)) + return command.run(targets=targets, props=None) def call(command, stdout=None, stderr=None): """ |