Skip to content

Commit

Permalink
fix cycling through completion suggestions ending in non-word character
Browse files Browse the repository at this point in the history
  • Loading branch information
Andriamanitra committed Feb 2, 2025
1 parent b432bb7 commit d5d9127
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions internal/action/actions.go
Original file line number Diff line number Diff line change
Expand Up @@ -911,6 +911,11 @@ func (h *BufPane) Autocomplete() bool {
return false
}

if b.HasSuggestions {
b.CycleAutocomplete(true)
return true
}

if h.Cursor.X == 0 {
return false
}
Expand All @@ -921,10 +926,6 @@ func (h *BufPane) Autocomplete() bool {
return false
}

if b.HasSuggestions {
b.CycleAutocomplete(true)
return true
}
return b.Autocomplete(buffer.BufferComplete)
}

Expand Down

0 comments on commit d5d9127

Please sign in to comment.