Created
March 9, 2021 22:28
-
-
Save NickCrew/257dceadc7c981de34151ce2e6403479 to your computer and use it in GitHub Desktop.
PowerShell Profile (CurrentUserAllHosts)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# ##################################################### | |
# | |
# Name: profile.ps1 | |
# Profile: CurrentUserAllHosts | |
# PSVersion: 7 | |
# | |
# Profile Load Order: | |
# - AllUsersAllHosts | |
# - AllUsersCurrentHost | |
# - CurrentUserAllHosts | |
# - CurrentUserCurrentHost | |
# | |
# ##################################################### | |
# PSReadline | |
Set-PSReadlineOption -EditMode vi | |
Set-PSReadlineOption -BellStyle None | |
Set-PSReadlineKeyHandler -Chord Ctrl+Alt+s -Function SwapCharacters | |
Set-PSReadlineKeyHandler -Key Alt+r -Function ViSearchHistoryBackward | |
Set-PSReadlineKeyHandler -Key Tab -Function MenuComplete | |
. "${PSScriptRoot}/Functions.ps1" | |
Set-Alias -Name co -Value code-insiders.cmd -Force | |
# this could go in CurrentUserCurrentHost but I like having it in VSCode terminal | |
Remove-PSReadlineKeyHandler 'Ctrl+r' | |
Remove-PSReadLineKeyHandler 'Alt+c' | |
Import-Module PSFZF | |
# replace standard tab completion with FZF completion | |
#Set-PSReadLineKeyHandler -Key Tab -ScriptBlock { Invoke-FzfTabCompletion } | |
Set-PsFzfOption -PSReadlineChordReverseHistory 'Ctrl+r' | |
Set-PsFzfOption -PSReadlineChordProvider 'Alt+c' | |
Set-PsFzfOption -TabExpansion | |
Set-PsFzfOption -EnableAliasFuzzyEdit | |
Set-PsFzfOption -EnableAliasFuzzyHistory | |
Set-PsFzfOption -EnableAliasFuzzyKillProcess | |
Set-PsFzfOption -EnableAliasFuzzySetLocation | |
Set-PsFzfOption -EnableAliasFuzzySetEverything | |
Set-PsFzfOption -EnableAliasFuzzyZLocation | |
Set-PsFzfOption -EnableAliasFuzzyGitStatus | |
Import-Module Get-ChildItemColor | |
Import-Module zlocation |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment