Verified Commit 88770c3c authored by Adam Mercer's avatar Adam Mercer 💬

attempt to build package using koji

parent ec918c27
......@@ -45,3 +45,7 @@ def list_pkgs(*args, **kwargs):
def add_pkg(*args, **kwargs):
return _koji_call('add-pkg', *args, **kwargs)
def build(*args, **kwargs):
return _koji_call('build', *args, **kwargs)
......@@ -125,6 +125,16 @@ def main():
logger.critical("unable to regsiter package: %s" % e)
raise
# attempt to build package
opts = [args.target, str(args.source)]
if args.scratch:
opts.insert(0, '--scratch')
try:
koji.build(*opts)
except subprocess.CalledProcessError as e:
logger.critical("unable to build package: %s" % e)
raise
logger.info("-- Complete -----")
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment