diff --git a/CHANGELOG.rst b/CHANGELOG.rst index f57ac5631..aeef1bea3 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -124,6 +124,7 @@ Interactive improvements - ``open`` no longer hangs indefinitely as a bug in ``xdg-open`` has been worked around (#7215). - Long command lines no longer add a blank line after execution (#6826) and behave better with backspace (#6951). - ``functions -t`` works as documented (#6985). +- History search now flashes when it found no more results (#7362) New or improved bindings ^^^^^^^^^^^^^^^^^^^^^^^^ diff --git a/src/reader.cpp b/src/reader.cpp index 9e2538610..50b022a68 100644 --- a/src/reader.cpp +++ b/src/reader.cpp @@ -3141,6 +3141,10 @@ void reader_data_t::handle_readline_command(readline_cmd_t c, readline_loop_stat ? history_search_direction_t::backward : history_search_direction_t::forward; bool found = history_search.move_in_direction(dir); + + // Signal that we've found nothing + if (!found) flash(); + if (!found && !was_active_before) { history_search.reset(); break;