GNU bug report logs -
#62263
28.1; Feature Request: Favorites variable support for minibuffers
Previous Next
Full log
Message #8 received at 62263 <at> debbugs.gnu.org (full text, mbox):
> If anyone can provide me with some hack around the history variable
> to emulate those benefits, i would be glad.
One example that you could look at is project--read-file-cpd-relative
where it filters out non-project history items:
(relname (cl-letf ((history-add-new-input nil)
((symbol-value hist)
(mapcan
(lambda (s)
(and (string-prefix-p abbr-cpd s)
(not (eq abbr-cpd-length (length s)))
(list (substring s abbr-cpd-length))))
(symbol-value hist))))
(project--completing-read-strict prompt
new-collection
predicate
hist mb-default)))
The same way you could filter out non-favorites from the currently
active history list symbol from minibuffer-history-variable for your
commands next-favorite-element and previous-favorite-element, or
in an advice-add around next-history-element/previous-history-element.
This bug report was last modified 2 years and 90 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.