Files
org-roam/20230522132448-helm_org_rifle.org
2025-11-05 09:18:11 +01:00

34 lines
1.9 KiB
Org Mode
Raw Permalink Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
:PROPERTIES:
:ID: 9ce51551-fcb1-446a-9924-9dd26f5d56aa
:END:
#+title: helm-org-rifle
#+filetags: :EMACS:ORG::
Fast-Search-Programme
This is my rifle. There are many like it, but this one is mine. My rifle is my best friend. It is my life. I must master it as I must master my life.
What does my rifle do? It searches rapidly through my Org files, quickly bringing me the information I need to defeat the enemy.
This package is inspired by org-search-goto/org-search-goto-ml. It searches both headings and contents of entries in Org buffers, and it displays entries that match all search terms, whether the terms appear in the heading, the contents, or both. Matching portions of entries contents are displayed with surrounding context and grouped by buffer to make it easy to acquire your target.
* Troubleshooting
If the package is loaded normally it works, but then annoying error messages are spit out. To fix this you have to set a simple '. The helm-org-rifle.el would then only have to be recompiled, or the corresponding function would have to be added to the init file.
#+begin_src emacs-lisp
(defun helm-org-rifle-get-source-for-buffer (buffer)
"Return Helm source for BUFFER."
(let ((source (helm-build-sync-source (buffer-name buffer)
:after-init-hook 'helm-org-rifle-after-init-hook ;;der sTrich muss hin (') wird aber in der helm-rifle.el nicht gesourced...
:candidates (lambda ()
(when (s-present? helm-pattern)
(helm-org-rifle--get-candidates-in-buffer (helm-attr 'buffer) helm-pattern)))
:candidate-transformer helm-org-rifle-transformer
:match 'identity
:multiline helm-org-rifle-multiline
:volatile t
:action 'helm-org-rifle-actions
:keymap helm-org-rifle-map)))
(helm-attrset 'buffer buffer source)
source))
#+end_src