If a full path is given to "pisi sf" we can get it from filesdb which gives a huge

time benefit.
This commit is contained in:
Faik Uygur
2008-12-02 12:15:40 +00:00
parent b25a4fecf3
commit a43c00a863
+4
View File
@@ -41,6 +41,10 @@ class FilesDB(lazydb.LazyDB):
return self.filesdb[md5.new(path).digest()], path
def search_file(self, term):
if self.has_file(term):
pkg, path = self.get_file(term)
return [(pkg,[path])]
installdb = pisi.db.installdb.InstallDB()
found = []
for pkg in installdb.list_installed():