1
0
mirror of https://github.com/openSUSE/osc.git synced 2024-11-12 23:56:13 +01:00

fix osc's ignorance of the revision option (-r) for expanded links

https://bugzilla.novell.com/show_bug.cgi?id=429650
This commit is contained in:
Dr. Peter Poeml 2008-11-19 12:13:18 +00:00
parent 9db331184b
commit 2bea1ad2df

View File

@ -1398,15 +1398,16 @@ Please submit there instead, or use --nodevelproject to force direct submission.
if len(pacs) > 1:
print 'Updating %s' % p.name
if opts.expand_link and p.islink() and not p.isexpanded():
print 'Expanding to rev', p.linkinfo.xsrcmd5
rev = p.linkinfo.xsrcmd5
elif opts.unexpand_link and p.islink() and p.isexpanded():
print 'Unexpanding to rev', p.linkinfo.lsrcmd5
rev = p.linkinfo.lsrcmd5
elif p.islink() and p.isexpanded():
rev = show_upstream_xsrcmd5(p.apiurl,
p.prjname, p.name)
if not rev:
if opts.expand_link and p.islink() and not p.isexpanded():
print 'Expanding to rev', p.linkinfo.xsrcmd5
rev = p.linkinfo.xsrcmd5
elif opts.unexpand_link and p.islink() and p.isexpanded():
print 'Unexpanding to rev', p.linkinfo.lsrcmd5
rev = p.linkinfo.lsrcmd5
elif p.islink() and p.isexpanded():
rev = show_upstream_xsrcmd5(p.apiurl,
p.prjname, p.name)
# FIXME: ugly workaround for #399247
if opts.expand_link or opts.unexpand_link: