From mboxrd@z Thu Jan 1 00:00:00 1970 From: Erik Hetzner Subject: Re: John's amazing indexing posts Date: Mon, 27 Jul 2015 09:40:25 -0700 Message-ID: <55b65efa.c765460a.f3aa8.1380@mx.google.com> References: <55b5bed5.4731460a.680f0.ffffb455@mx.google.com> <87egjt3fh4.fsf@gmail.com> Reply-To: Erik Hetzner Mime-Version: 1.0 (generated by SEMI-EPG 1.14.7 - "Harue") Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:60795) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZJlS4-00028q-4w for emacs-orgmode@gnu.org; Mon, 27 Jul 2015 12:40:33 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZJlS0-0006Od-OP for emacs-orgmode@gnu.org; Mon, 27 Jul 2015 12:40:32 -0400 Received: from mail-pa0-x22b.google.com ([2607:f8b0:400e:c03::22b]:34586) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZJlS0-0006OX-Hf for emacs-orgmode@gnu.org; Mon, 27 Jul 2015 12:40:28 -0400 Received: by pacan13 with SMTP id an13so55179024pac.1 for ; Mon, 27 Jul 2015 09:40:27 -0700 (PDT) In-Reply-To: <87egjt3fh4.fsf@gmail.com> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Oleh Krehel Cc: Org Mode , John Kitchin Hi Oleh, On Mon, 27 Jul 2015 06:19:35 -0700, Oleh Krehel wrote: >=20 >=20 > Hi Erik, >=20 > Erik Hetzner writes: > > I previously hooked up org with recoll with pretty good results. > > ... > > http://www.lesbonscomptes.com/recoll/ >=20 > Thanks for the link. I tried it, and it actually works great on my > system (unlike swish-e). And I did no configuration of mimeinfo, I only > told it to index my whole org/ directory. Of course! I=E2=80=99ve forgotten exactly what I was intending to accomplish by converting to HTML - I believe I was generating citations - but recoll should be able to index plain text without issue. This will probably work better for org files, as well, since you can search the complete content. > If anyone is interested, I've added an Emacs interface to recallq (a > shell tool that comes with recoll that you have to build yourself). See > counsel-recoll command from > https://github.com/abo-abo/swiper/blob/master/counsel.el. >=20 > Initially, this command gives you a list of files that match the > query. After selecting the file, it's searched for the current query. > Unfortunately, the -A (abstract) switch isn't as useful as the context > that e.g. grep gives, so I went only with the file names. This is great, especially for me, as I=E2=80=99ve been using ivy lately. I believe that you can rewrite using the recoll tool directly instead of recollq, using `recoll -t -b 'search string'`: (defun counsel-recoll-function (string &optional _pred &rest _unused) "Grep in the current directory for STRING." (if (< (length string) 3) (counsel-more-chars 3) (counsel--async-command (format "recoll -t -b '%s'" string)) nil)) If you use `recoll -A -t 'search string'` and do some post processing you could get snippets, too. I can=E2=80=99t see how to do that easily with counsel--async-command, though. best, Erik -- Sent from my free software system .