-
Notifications
You must be signed in to change notification settings - Fork 54
Configuration
Bruce D'Arcus edited this page Apr 12, 2021
·
38 revisions
The README includes a section on this. If you have other setups you use, put them here.
Possible script. Feel to improve this:
(defun my/add-bib-watches (paths)
"Add path watches for all PATHS."
;; TODO add message for success/failure; what about removal?
(let ((flat-paths (-flatten paths)))
(cl-loop
for path in flat-paths
do
(file-notify-add-watch
path '(change) 'bibtex-actions-refresh))))
(defvar my/bib-paths
(list
bibtex-completion-bibliography
bibtex-completion-notes-path
bibtex-completion-library-path
"My bib paths."))
;; Add watches for all bib paths.
(my/add-bib-watches my/bib-paths)
(setq bibtex-actions-template
'((t . "${=has-pdf=:1} ${=has-note=:1} ${author:24} ${title:64} ${year:4}")))
TODO
TODO
Bind the keymap to embark-act
like so:
(add-to-list 'embark-keymap-alist '(bibtex . bibtex-actions-map))
You have, again, options.
You can setup the default prompter per the embark README.
This commit also adds an option to use prefix completion.
This variable will configure which-key to sort the bindings so the bibtex-action ones are grouped first.
(setq which-key-sort-order 'which-key-description-order)
For marking candidates in the embark-collect
buffer.
TODO Still need code to bind this to embark.
This allows you to bypass the embark-act
command and invoke actions directly within a collect buffer.