Skip to content

Instantly share code, notes, and snippets.

@timmkrause
Last active October 25, 2021 20:10
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save timmkrause/566bec42e6da44f6f8ea9fa872f8ef90 to your computer and use it in GitHub Desktop.
Save timmkrause/566bec42e6da44f6f8ea9fa872f8ef90 to your computer and use it in GitHub Desktop.
PowerShell Profile
# Inspiration: https://gist.github.com/shanselman/25f5550ad186189e0e68916c6d7f44c3
oh-my-posh --init --shell pwsh --config "C:\...\timm.omp.json" | Invoke-Expression
Import-Module -Name Terminal-Icons
Set-PSReadLineOption -PredictionSource History
Set-PSReadLineOption -PredictionViewStyle ListView
Set-PSReadLineOption -EditMode Windows
# PowerShell parameter completion shim for the dotnet CLI
Register-ArgumentCompleter -Native -CommandName dotnet -ScriptBlock {
param($commandName, $wordToComplete, $cursorPosition)
dotnet complete --position $cursorPosition "$wordToComplete" | ForEach-Object {
[System.Management.Automation.CompletionResult]::new($_, $_, 'ParameterValue', $_)
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment