From owner-freebsd-ruby@FreeBSD.ORG Sun Sep 20 21:27:24 2009 Return-Path: Delivered-To: ruby@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id D32AF1065670 for ; Sun, 20 Sep 2009 21:27:24 +0000 (UTC) (envelope-from afb@algonet.se) Received: from ch-smtp03.sth.basefarm.net (ch-smtp03.sth.basefarm.net [80.76.149.214]) by mx1.freebsd.org (Postfix) with ESMTP id 94F498FC15 for ; Sun, 20 Sep 2009 21:27:24 +0000 (UTC) Received: from c83-248-162-176.bredband.comhem.se ([83.248.162.176]:56922 helo=[10.0.1.101]) by ch-smtp03.sth.basefarm.net with esmtp (Exim 4.68) (envelope-from ) id 1MpThP-0003Eg-By for ruby@FreeBSD.org; Sun, 20 Sep 2009 23:12:01 +0200 Mime-Version: 1.0 (Apple Message framework v753.1) Content-Transfer-Encoding: 7bit Message-Id: Content-Type: text/plain; charset=US-ASCII; format=flowed To: ruby@FreeBSD.org From: =?ISO-8859-1?Q?Anders_F_Bj=F6rklund?= Date: Sun, 20 Sep 2009 23:11:56 +0200 X-Mailer: Apple Mail (2.753.1) X-Originating-IP: 83.248.162.176 X-Scan-Result: No virus found in message 1MpThP-0003Eg-By. X-Scan-Signature: ch-smtp03.sth.basefarm.net 1MpThP-0003Eg-By 8f57f7882b5dafbf64cb907960cf1d2f Cc: Subject: portlocate program X-BeenThere: freebsd-ruby@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: FreeBSD-specific Ruby discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 20 Sep 2009 21:27:24 -0000 Hi pkgtools maintainers, I made a ruby program that I called "portlocate": (since portsearch and variants were taken already) http://www.algonet.se/~afb/freebsd/portlocate.rb It updates and searches an extra database with the *full* details of each port, for fast searching. You pass some search terms, and you get matching ports in order of relevance (best matches first). It uses the Ruby bindings to the Xapian database, but has a --slow fallback if those are missing... http://www.freebsd.org/cgi/cvsweb.cgi/ports/databases/xapian-bindings/ The intended use is for the Search Details feature of PackageKit, where it cuts the search time from 5-15 seconds down to 1 second consistently here - and additionally it returns the best matches first. I think it would make a good addition to portupgrade, but it could also be deployed separately of course ? --anders