summaryrefslogtreecommitdiffstats
path: root/src/fedpkg.py
diff options
context:
space:
mode:
Diffstat (limited to 'src/fedpkg.py')
-rwxr-xr-xsrc/fedpkg.py13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/fedpkg.py b/src/fedpkg.py
index 2219a38..656464e 100755
--- a/src/fedpkg.py
+++ b/src/fedpkg.py
@@ -460,6 +460,14 @@ def gimmespec(args):
log.error('Could not get spec file: %s' % e)
sys.exit(1)
+def giturl(args):
+ try:
+ mymodule = pyfedpkg.PackageModule(args.path)
+ print(mymodule.giturl())
+ except pyfedpkg.FedpkgError, e:
+ log.error('Could not get the giturl: %s' % e)
+ sys.exit(1)
+
def import_srpm(args):
# See if we need to create a module from scratch, and do so
if args.create:
@@ -871,6 +879,11 @@ packages will be built sequentially.
help = 'print spec file name')
parser_gimmespec.set_defaults(command = gimmespec)
+ # giturl
+ parser_giturl = subparsers.add_parser('giturl',
+ help = 'print the url for building')
+ parser_giturl.set_defaults(command = giturl)
+
# Import content into a module
parser_import_srpm = subparsers.add_parser('import',
help = 'Import content into a module')