1
0
mirror of https://github.com/openSUSE/osc.git synced 2025-01-26 22:56:15 +01:00

Support git@ (private github) or git:// URLs correctly

This commit is contained in:
Adrian Schröter 2020-05-05 10:35:56 +02:00
parent 9aa3777a60
commit 5d6351b1bd

View File

@ -4668,11 +4668,10 @@ Please submit there instead, or use --nodevelproject to force direct submission.
# Do some magic here, when adding a url. We want that the server to download the tar ball and to verify it
for arg in parseargs(args):
if arg.startswith('http://') or arg.startswith('https://') or arg.startswith('ftp://') or arg.startswith('git://'):
if arg.endswith('.git'):
addGitSource(arg)
else:
addDownloadUrlService(arg)
if arg.endswith('.git') or arg.startswith('git://') or arg.startswith('git@'):
addGitSource(arg)
elif arg.startswith('http://') or arg.startswith('https://') or arg.startswith('ftp://'):
addDownloadUrlService(arg)
else:
addFiles([arg])