Skip to content

Commit

Permalink
Merge pull request #2548 from carapace-sh/git-refrange-simpler
Browse files Browse the repository at this point in the history
git: ActionRefRanges - no need for invoke
  • Loading branch information
rsteube authored Oct 13, 2024
2 parents 0858bd5 + d984995 commit 7b571b1
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions pkg/actions/tools/git/ref.go
Original file line number Diff line number Diff line change
Expand Up @@ -105,8 +105,7 @@ func ActionRefs(refOption RefOption) carapace.Action {
func ActionRefRanges(opts RefOption) carapace.Action {
return carapace.ActionCallback(func(c carapace.Context) carapace.Action {
if strings.HasPrefix(c.Value, "^") { // negate
c.Value = c.Value[1:]
return ActionRefs(opts).Invoke(c).ToA().NoSpace().Prefix("^")
return ActionRefs(opts).NoSpace().Prefix("^")
}

delimiter := ".."
Expand Down

0 comments on commit 7b571b1

Please sign in to comment.