fix(search): allow searching for a literal \c or \r

A query that starts with one of the two modifier prefixes could not be
escaped, so the text itself was unreachable: \c and \r were always consumed
as modifiers and the query ended up empty. A doubled backslash now ends the
modifier section and stands for the literal backslash, and the help line and
the docs document it.

Fixes #48
This commit is contained in:
BlackAngelTV committed 2026-12-03 10:01:34 +01:00
1 parent 1bd822b9e5
commit f616651c49
5 files changed
+37 -6

No files matched your search

+3 -2
View File
@@ -277,8 +277,9 @@ Detailed list of changes
highlights every match without opening the pager, shows the
:code:`[current/total]` counter in the window title and moves between matches
with :kbd:`n` and :kbd:`N`. Prefix the query with :code:`\c` for a case
sensitive search and :code:`\r` for a regular expression. See
:doc:`basic` for the details.
sensitive search and :code:`\r` for a regular expression; write a doubled
backslash (:code:`\\c`, :code:`\\r`) to search for those prefixes literally.
See :doc:`basic` for the details.
- A configurable :opt:`leader` key now opens a which-key panel listing every
multi-key mapping available under that prefix, without waiting for a timeout.