From debbugs-submit-bounces@debbugs.gnu.org Wed Jun 26 04:43:56 2019 Received: (at submit) by debbugs.gnu.org; 26 Jun 2019 08:43:56 +0000 Received: from localhost ([127.0.0.1]:34205 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hg3X1-00088p-TK for submit@debbugs.gnu.org; Wed, 26 Jun 2019 04:43:56 -0400 Received: from lists.gnu.org ([209.51.188.17]:42380) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hg3X0-00088i-Ia for submit@debbugs.gnu.org; Wed, 26 Jun 2019 04:43:54 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:50310) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hg3Wz-0000s7-KQ for guix-patches@gnu.org; Wed, 26 Jun 2019 04:43:54 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-0.2 required=5.0 tests=ALL_TRUSTED,BAYES_50 autolearn=disabled version=3.3.2 Received: from fencepost.gnu.org ([2001:470:142:3::e]:47106) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hg3Wz-0002YG-GV; Wed, 26 Jun 2019 04:43:53 -0400 Received: from [2a01:e0a:1d:7270:af76:b9b:ca24:c465] (port=34174 helo=gnu.org) by fencepost.gnu.org with esmtpsa (TLS1.2:DHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1hg3Wz-0000pw-0j; Wed, 26 Jun 2019 04:43:53 -0400 From: =?UTF-8?q?Ludovic=20Court=C3=A8s?= To: guix-patches@gnu.org Subject: [PATCH 0/3] Improve 'guix search' relevance and display Date: Wed, 26 Jun 2019 10:43:38 +0200 Message-Id: <20190626084338.3153-1-ludo@gnu.org> X-Mailer: git-send-email 2.22.0 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: submit Cc: =?UTF-8?q?Ludovic=20Court=C3=A8s?= X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Hello Guix! This improves ‘guix search’ in two ways: 1. The relevance score now excludes things that do not match *all* the regexps. So ‘guix search go game’ returns 28 results instead of 1,245 and the first one is ‘gnugo’; ‘guix search ssh client’ returns 14 results instead of 510; ‘guix search guile crypto’ returns just ‘guile-gcrypt’ instead of 279 results. 2. ‘guix search’ and ‘guix system search’ now write at most a full screen of results. You can pipe through a pager to view all the results. Thoughts? Ludo’. Ludovic Courtès (3): ui: 'relevance' considers regexps connected with a logical and. syscalls: Add 'terminal-rows'. ui: Add 'display-search-results' and use it. guix/build/syscalls.scm | 37 +++++++++++------ guix/scripts/package.scm | 41 ++++++++----------- guix/scripts/system/search.scm | 44 +++++++++----------- guix/ui.scm | 75 ++++++++++++++++++++++++++++------ tests/syscalls.scm | 5 ++- tests/ui.scm | 27 +++++++++++- 6 files changed, 155 insertions(+), 74 deletions(-) -- 2.22.0