helm-org-in-buffer-headings, mu4e-company
This commit is contained in:
parent
5cda6fd005
commit
426180b232
9
init.el
9
init.el
@ -912,6 +912,15 @@ The current directory is assumed to be the project's root otherwise."
|
|||||||
(use-package helm-ag :ensure t))
|
(use-package helm-ag :ensure t))
|
||||||
:config
|
:config
|
||||||
(progn
|
(progn
|
||||||
|
(cl-defun helm-org-in-buffer-headings ()
|
||||||
|
(interactive)
|
||||||
|
(helm :sources (helm-source-org-headings-for-files
|
||||||
|
|
||||||
|
(list (projectile-completing-read
|
||||||
|
"File to look at headings from: "
|
||||||
|
(projectile-all-project-files))))
|
||||||
|
:candidate-number-limit 99999
|
||||||
|
:buffer "*helm org inbuffer*"))
|
||||||
;; helm zsh source history
|
;; helm zsh source history
|
||||||
(defvar helm-c-source-zsh-history
|
(defvar helm-c-source-zsh-history
|
||||||
'((name . "Zsh History")
|
'((name . "Zsh History")
|
||||||
|
15
load.d/mu4e-company.el
Normal file
15
load.d/mu4e-company.el
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
(defun mu4e-company-contacts (command &optional input &rest ignored)
|
||||||
|
(interactive (list 'interactive))
|
||||||
|
(cl-case command
|
||||||
|
(interactive (company-begin-backend 'mu4e-contacts-company))
|
||||||
|
(prefix
|
||||||
|
(when (eq major-mode 'mu4e-compose-mode)
|
||||||
|
(save-excursion
|
||||||
|
(beginning-of-line)
|
||||||
|
(if (and (eq (line-number-at-pos) 2)
|
||||||
|
(looking-at "^To: *\\(.*?\\)$"))
|
||||||
|
(match-string-no-properties 1)
|
||||||
|
'stop))))
|
||||||
|
(candidates
|
||||||
|
(--filter (string-match-p (downcase input) (downcase it))
|
||||||
|
mu4e~contacts-for-completion))))
|
Loading…
Reference in New Issue
Block a user