summaryrefslogtreecommitdiffstats
path: root/src/fedpkg.py
diff options
context:
space:
mode:
authorJesse Keating <jkeating@redhat.com>2010-06-23 21:53:30 -0700
committerJesse Keating <jkeating@redhat.com>2010-06-23 21:53:30 -0700
commitd36e9ea5bc55d189735ef9f55433ffff5b52550a (patch)
tree15f30614e4a1d6877322743dcdfe619c1c25c680 /src/fedpkg.py
parentde54e4350bec675ad9ded1dc745aae3c5887de1a (diff)
downloadfedora-packager-d36e9ea5bc55d189735ef9f55433ffff5b52550a.zip
fedora-packager-d36e9ea5bc55d189735ef9f55433ffff5b52550a.tar.gz
fedora-packager-d36e9ea5bc55d189735ef9f55433ffff5b52550a.tar.xz
Move import_srpm out of the class
This is so that we can use it before we have a full fledged module to deal with, like creating something local to play with.
Diffstat (limited to 'src/fedpkg.py')
-rwxr-xr-xsrc/fedpkg.py16
1 files changed, 8 insertions, 8 deletions
diff --git a/src/fedpkg.py b/src/fedpkg.py
index 1c1f0af..6e12776 100755
--- a/src/fedpkg.py
+++ b/src/fedpkg.py
@@ -441,17 +441,17 @@ def import_srpm(args):
if not args.create:
try:
mymodule = pyfedpkg.PackageModule(args.path)
- if not mymodule.import_srpm(args.srpm):
- print("New content staged and new sources uploaded.")
- print("Review with: git diff --cached")
- print("Commit if happy or revert with: git reset --hard HEAD")
- return
- else:
- log.error("Unable to import srpm")
- sys.exit(1)
+ uploadfiles = pyfedpkg.import_srpm(mymodule.repo, args.srpm)
except pyfedpkg.FedpkgError, e:
log.error('Could import srpm: %s' % e)
sys.exit(1)
+ # replace this system call with a proper diff target when it is
+ # readys
+ os.system('GIT_PAGER='' git diff --cached')
+ print('--------------------------------------------')
+ print("New content staged and new sources uploaded.")
+ print("Commit if happy or revert with: git reset --hard HEAD")
+ return
def install(args):
arch = None