2024-06-09 17:48:29 -05:00
|
|
|
Register-ArgumentCompleter -Native -CommandName winget -ScriptBlock {
|
|
|
|
param($wordToComplete, $commandAst, $cursorPosition)
|
|
|
|
[Console]::InputEncoding = [Console]::OutputEncoding = $OutputEncoding = [System.Text.Utf8Encoding]::new()
|
|
|
|
$Local:word = $wordToComplete.Replace('"', '""')
|
|
|
|
$Local:ast = $commandAst.ToString().Replace('"', '""')
|
|
|
|
winget complete --word="$Local:word" --commandline "$Local:ast" --position $cursorPosition | ForEach-Object {
|
|
|
|
[System.Management.Automation.CompletionResult]::new($_, $_, 'ParameterValue', $_)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
2024-06-10 17:17:01 -05:00
|
|
|
function dot { & git --git-dir="$HOME/.dot/" --work-tree="$HOME" @args }
|
2024-06-09 17:48:29 -05:00
|
|
|
|
2024-06-10 17:17:01 -05:00
|
|
|
# Source the aliases.ps1 file
|
|
|
|
. "$PSScriptRoot/aliases.ps1"
|