1
0
mirror of https://github.com/openSUSE/osc.git synced 2025-09-08 05:58:43 +02:00

Merge pull request #446 from lethliel/add_error_for_issue_445

print error and exit if p.apiurl != -A <apiurl> using osc sr
This commit is contained in:
Marco Strigl
2019-09-17 14:11:20 +02:00
committed by GitHub

View File

@@ -1331,6 +1331,10 @@ class Osc(cmdln.Cmdln):
p = findpacs(os.curdir)[0]
src_project = p.prjname
src_package = p.name
if self.options.apiurl and self.options.apiurl != p.apiurl:
print('The apiurl for the working copy of this package is %s' % p.apiurl)
print('You cannot use this command with the -A %s option.' % self.options.apiurl)
sys.exit(1)
apiurl = p.apiurl
if len(args) == 0 and p.islink():
dst_project = p.linkinfo.project