Unnamed repository; edit this file 'description' to name the repository.
Use `^` and `$` to match the beginning and end of a line when searching (#1790)
Fixes #1737 Signed-off-by: nibon7 <[email protected]>
nibon7 2022-03-12
parent 61828ea · commit 43997f1
-rw-r--r--helix-term/src/commands.rs1
-rw-r--r--helix-term/src/ui/mod.rs1
2 files changed, 2 insertions, 0 deletions
diff --git a/helix-term/src/commands.rs b/helix-term/src/commands.rs
index 0052b43e..b9401d40 100644
--- a/helix-term/src/commands.rs
+++ b/helix-term/src/commands.rs
@@ -1642,6 +1642,7 @@ fn search_next_or_prev_impl(cx: &mut Context, movement: Movement, direction: Dir
let wrap_around = search_config.wrap_around;
if let Ok(regex) = RegexBuilder::new(query)
.case_insensitive(case_insensitive)
+ .multi_line(true)
.build()
{
search_impl(
diff --git a/helix-term/src/ui/mod.rs b/helix-term/src/ui/mod.rs
index 6299a473..2273477f 100644
--- a/helix-term/src/ui/mod.rs
+++ b/helix-term/src/ui/mod.rs
@@ -73,6 +73,7 @@ pub fn regex_prompt(
match RegexBuilder::new(input)
.case_insensitive(case_insensitive)
+ .multi_line(true)
.build()
{
Ok(regex) => {