2023-07-03 19:43:36 +00:00
|
|
|
#!/usr/bin/python3
|
|
|
|
"""
|
|
|
|
Import a source RPM into a git forge using pv2
|
|
|
|
"""
|
|
|
|
|
|
|
|
import argparse
|
|
|
|
import pv2.importer as importutil
|
|
|
|
|
2023-07-07 21:37:56 +00:00
|
|
|
parser = argparse.ArgumentParser(description="Importer")
|
2023-07-03 19:43:36 +00:00
|
|
|
|
|
|
|
parser.add_argument('--giturl', type=str, required=True)
|
|
|
|
parser.add_argument('--branch', type=str, required=True)
|
|
|
|
parser.add_argument('--srpm', type=str, required=True)
|
|
|
|
parser.add_argument('--release', type=str, required=False, default='')
|
|
|
|
results = parser.parse_args()
|
|
|
|
# pylint: disable=line-too-long
|
|
|
|
classy = importutil.SrpmImport(git_url_path=results.giturl, srpm_path=results.srpm, branch=results.branch, release=results.release)
|
|
|
|
classy.pkg_import()
|