diff options
Diffstat (limited to 'mgagnome')
-rwxr-xr-x | mgagnome | 14 |
1 files changed, 12 insertions, 2 deletions
@@ -979,6 +979,16 @@ class Downstream(object): cmd.append(package) return subprocess.check_call(cmd, cwd=cwd) + @classmethod + @retry(subprocess.CalledProcessError) + def ci(cls, package, changes, cwd=None): + if cwd is None: + cwd = os.path.expanduser(cls.PKGROOT) + + cmd = ['mgarepo', 'ci', '-m', changes] + return subprocess.check_call(cmd, cwd=cwd) + + def get_downstream_from_upstream(self, upstream, version): if upstream not in self.tarballs: raise ValueError("No packages for upstream name: %s" % upstream) @@ -1307,7 +1317,7 @@ def cmd_clean_spec_multi(args): # If we made it this far, checkin the changes if made_changes: if options.doit: - subprocess.check_call(['mgarepo', 'ci', '-m', s.changes], cwd=cwd) + Downstream.ci(package, s.changes, cwd=cwd) else: # show the diff and undo all changes print s.changes @@ -1376,7 +1386,7 @@ def cmd_package_new_version(options, parser): try: # If we made it this far, checkin the changes - subprocess.check_call(['mgarepo', 'ci', '-m', s.changes], cwd=cwd) + Downstream.ci(package, s.changes, cwd=cwd) # Submit is optional if options.submit: |