Skip to content

Commit

Permalink
Merge pull request #2646 from carapace-sh/powershell-fix-trim
Browse files Browse the repository at this point in the history
powershell: fix trimend
  • Loading branch information
rsteube authored Dec 17, 2024
2 parents 7b7cc17 + 34ad375 commit 08c3a82
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 08c3a82

Please sign in to comment.