mirror of
https://git.launchpad.net/~ubuntu-release/britney/+git/britney2-ubuntu
synced 2025-05-08 09:01:36 +00:00
Re-added support for completing removals in tab-completer
The broken "do_hint" was caused by lack of versions in the resulting hint. Signed-off-by: Niels Thykier <niels@thykier.net>
This commit is contained in:
parent
5ef956489a
commit
34467e964a
10
completer.py
10
completer.py
@ -34,15 +34,15 @@ class Completer:
|
|||||||
# - it might contain too many items, but meh
|
# - it might contain too many items, but meh
|
||||||
complete = []
|
complete = []
|
||||||
for e in britney.excuses:
|
for e in britney.excuses:
|
||||||
if e.name[0] == '-':
|
|
||||||
# do_hint does not work with removals anyway
|
|
||||||
continue
|
|
||||||
else:
|
|
||||||
ver = None
|
ver = None
|
||||||
pkg = e.name
|
pkg = e.name
|
||||||
|
suite = 'unstable'
|
||||||
|
if pkg[0] == '-':
|
||||||
|
suite = 'testing'
|
||||||
|
pkg = pkg[1:]
|
||||||
if "/" in pkg:
|
if "/" in pkg:
|
||||||
pkg = pkg.split("/")[0]
|
pkg = pkg.split("/")[0]
|
||||||
name = "%s/%s" % (e.name, britney.sources['unstable'][pkg][0]) # 0 == VERSION
|
name = "%s/%s" % (e.name, britney.sources[suite][pkg][0]) # 0 == VERSION
|
||||||
complete.append(name)
|
complete.append(name)
|
||||||
self.packages = sorted(complete)
|
self.packages = sorted(complete)
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user