diff options
Diffstat (limited to 'g_common/g_common.py')
-rw-r--r-- | g_common/g_common.py | 15 |
1 files changed, 11 insertions, 4 deletions
diff --git a/g_common/g_common.py b/g_common/g_common.py index 33b7664..216ca06 100644 --- a/g_common/g_common.py +++ b/g_common/g_common.py @@ -161,11 +161,15 @@ def generate_tree(repo_location,generate_manifest,generate_metadata): return 0 #list package details, in PMS's format -def action_package(repo_location,package_name): +def action_package(repo_location,package_name,version): repo_conf=read_repo_config(repo_location) driver_conf=read_driver_config(repo_conf['driver']) - - return os.system(driver_conf['exec']+" "+repo_location+" package "+package_name) + + version_append='' + if version: + version_append=' '+version + + return os.system(driver_conf['exec']+" "+repo_location+" package "+package_name+version_append) #do one of the ebuild phases def exec_phase(repo_location,phase): @@ -223,7 +227,10 @@ def main(): print " * [version]" sys.exit(1) package_name=arguments[2] - return action_package(repo_location,package_name) + version=None + if len(arguments)>3: #version + version=arguments[3] + return action_package(repo_location,package_name,version) elif action=='usage' or action=='help': return usage() elif action in settings.PMS_PHASES: |