Skip to content

Commit

Permalink
powershell: fix trimend
Browse files Browse the repository at this point in the history
  • Loading branch information
rsteube committed Dec 17, 2024
1 parent 7b7cc17 commit 34ad375
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion cmd/carapace/cmd/lazyinit/powershell.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ func Powershell(completers []string) string {
$_carapace_lazy = {
param($wordToComplete, $commandAst, $cursorPosition)
$completer = $commandAst.CommandElements[0].Value.trimend(".exe")
$completer = $commandAst.CommandElements[0].Value.Replace("\.exe$", "")
carapace $completer powershell | Out-String | Invoke-Expression
& (Get-Item "Function:_${completer}_completer") $wordToComplete $commandAst $cursorPosition
}
Expand Down

0 comments on commit 34ad375

Please sign in to comment.