diff options
Diffstat (limited to 'portato')
-rw-r--r-- | portato/backend/portage/sets.py | 6 | ||||
-rw-r--r-- | portato/gui/windows/main.py | 3 |
2 files changed, 3 insertions, 6 deletions
diff --git a/portato/backend/portage/sets.py b/portato/backend/portage/sets.py index 59641df..dd8257d 100644 --- a/portato/backend/portage/sets.py +++ b/portato/backend/portage/sets.py @@ -52,7 +52,7 @@ class FilterSet (Set): t = set() for pkg in self.get_list(): if is_regexp and key: - if not re.match(key, pkg, re.I): continue + if not re.search(key, pkg, re.I): continue if not with_version: t.add(portage.dep.dep_getkey(pkg)) @@ -97,7 +97,7 @@ class InstalledSet (Set): t = system.settings.vartree.dbapi.cp_all() if key: - t = filter(lambda x: re.match(key, x, re.I), t) + t = filter(lambda x: re.search(key, x, re.I), t) return set(t) else: @@ -113,7 +113,7 @@ class TreeSet (Set): t = system.settings.porttree.dbapi.cp_all() if key: - t = filter(lambda x: re.match(key, x, re.I), t) + t = filter(lambda x: re.search(key, x, re.I), t) elif masked: t = system.settings.porttree.dbapi.xmatch("match-all", key) diff --git a/portato/gui/windows/main.py b/portato/gui/windows/main.py index 19fa35f..87a13dc 100644 --- a/portato/gui/windows/main.py +++ b/portato/gui/windows/main.py @@ -1616,9 +1616,6 @@ class MainWindow (Window): """Do a search.""" text = entry.get_text() if text != "": - if "/" not in text: - text = "/.*"+text # only look for package names - packages = system.find_packages(text, with_version = False) if packages == []: |