exit conditional replace if no match is left

This commit is contained in:
boombuler
2016-09-04 09:29:26 +02:00
parent 98b6f63b70
commit fce5b81c22

View File

@@ -291,6 +291,9 @@ func Replace(args []string) {
for {
// The 'check' flag was used
Search(search, view, true)
if !view.Cursor.HasSelection() {
break
}
view.Relocate()
if view.Buf.Settings["syntax"].(bool) {
view.matches = Match(view)