Skip to content

Commit

Permalink
Merge pull request #2120 from rsteube/git-changes-prefix
Browse files Browse the repository at this point in the history
git: ActionChanges - support `./` path prefix
  • Loading branch information
rsteube authored Jan 5, 2024
2 parents ef55637 + a031e40 commit b2c80eb
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion pkg/actions/tools/git/change.go
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,12 @@ func ActionChanges(opts ChangeOpts) carapace.Action {
}
}
}
return carapace.ActionStyledValuesDescribed(untracked...)

action := carapace.ActionStyledValuesDescribed(untracked...)
if strings.HasPrefix(c.Value, "./") {
action = action.Prefix("./")
}
return action
}
})
}).Tag("changed files")
Expand Down

0 comments on commit b2c80eb

Please sign in to comment.