Helm interface for the recoll desktop search tool.
Create recoll indexes
First you have to create an index for each directory you want
to index, for this create some directories like “~/.recoll-<your-directory-name>”
then create “recoll.conf” config files in each directory containing
topdirs = <full/path/to/your/directory>
recollindex -c ~/.recoll-<your-directory-name>
to create index for each directory.
for more infos.
You can also create recoll index directories from
adding following code to your config:
(defun helm-ff-recoll-index-directory (directory) "Create a recoll index directory from DIRECTORY. Add the new created directory to `helm-recoll-directories' using the basename of DIRECTORY as name. By using `customize-set-variable', a new source is created for this new directory." (cl-assert (boundp 'helm-recoll-directories) nil "Package helm-recoll not installed or configured") (let* ((bn (helm-basename (expand-file-name directory))) (index-dir (format "~/.recoll-%s" bn)) (conf-file (expand-file-name "recoll.conf" index-dir))) (mkdir index-dir) (with-current-buffer (find-file-noselect conf-file) (insert (format "topdirs = %s" (expand-file-name directory))) (save-buffer) (kill-buffer)) (customize-set-variable 'helm-recoll-directories (append `((,bn . ,index-dir)) helm-recoll-directories)) (message "Don't forget to index config directory with 'recollindex -c %s'" index-dir))) (defmethod helm-setup-user-source ((source helm-source-ffiles)) (helm-source-add-action-to-source-if "Recoll index directory" 'helm-ff-recoll-index-directory source 'file-directory-p 3))
You will just need to index recoll directory with same
command as described above.
Then you need to create some helm-recoll sources before you can use them.
You can create sources by customizing
Then just call
will build a specific command for each directory and the specific sources for
helm-recoll-directories (see above)
helm-recoll or even better autoload the
If you use
use-package you can use e.g.
(use-package helm-recoll :commands helm-recoll :init (setq helm-recoll-directories '(("confdir" . "~/.recoll-.emacs.d") ("lisp sources" . "~/.recoll-elisp") ("work" . "~/.recoll-work"))))
Otherwise add a require statement for the library:
to your init file and setup