Make custom consult bookmark menu robust for upgrade
`consult--source-bookmark` is gone in later versions.
This commit is contained in:
parent
0ecb4ff55a
commit
575b78a0b2
@ -101,7 +101,13 @@
|
|||||||
:annotate #'(lambda (_) "")
|
:annotate #'(lambda (_) "")
|
||||||
:action #'call-interactively)
|
:action #'call-interactively)
|
||||||
sources)
|
sources)
|
||||||
(push 'consult--source-bookmark
|
(push (cond
|
||||||
|
((boundp 'consult-source-bookmark)
|
||||||
|
'consult-source-bookmark)
|
||||||
|
((boundp 'consult--source-bookmark)
|
||||||
|
'consult--source-bookmark)
|
||||||
|
(t
|
||||||
|
(error "No consult source for adding bookmarks")))
|
||||||
sources)
|
sources)
|
||||||
(when (file-directory-p db/important-documents-path)
|
(when (file-directory-p db/important-documents-path)
|
||||||
(let ((search-path (expand-file-name db/important-documents-path)))
|
(let ((search-path (expand-file-name db/important-documents-path)))
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user