move to ohmyposh for zsh
This commit is contained in:
parent
180a12c694
commit
953fca03c8
5 changed files with 89 additions and 272 deletions
|
|
@ -1,25 +1,25 @@
|
|||
oh-my-posh init pwsh --config ~/.config/powershell/config.json | Invoke-Expression
|
||||
oh-my-posh init pwsh --config ~/.config/ohmyposh/config.toml | Invoke-Expression
|
||||
Set-PSReadLineOption -PredictionSource History
|
||||
|
||||
@(
|
||||
"cat,get-content"
|
||||
"cd,set-location"
|
||||
"clear,clear-host"
|
||||
"cp,copy-item"
|
||||
"history,get-history"
|
||||
"kill,stop-process"
|
||||
"ls,Get-ChildItem"
|
||||
"mv,move-item"
|
||||
"ps,get-process"
|
||||
"pwd,get-location"
|
||||
"which,get-command"
|
||||
"open,Invoke-Item"
|
||||
"basename,Split-Path"
|
||||
"realpath,resolve-path"
|
||||
"cat,get-content"
|
||||
"cd,set-location"
|
||||
"clear,clear-host"
|
||||
"cp,copy-item"
|
||||
"history,get-history"
|
||||
"kill,stop-process"
|
||||
"ls,Get-ChildItem"
|
||||
"mv,move-item"
|
||||
"ps,get-process"
|
||||
"pwd,get-location"
|
||||
"which,get-command"
|
||||
"open,Invoke-Item"
|
||||
"basename,Split-Path"
|
||||
"realpath,resolve-path"
|
||||
) | ForEach-Object {
|
||||
$Alias = ($PSItem -split ",")[0]
|
||||
$value = ($PSItem -split ",")[1]
|
||||
Set-Alias -Name $Alias -Value $value -Option AllScope
|
||||
$Alias = ($PSItem -split ",")[0]
|
||||
$value = ($PSItem -split ",")[1]
|
||||
Set-Alias -Name $Alias -Value $value -Option AllScope
|
||||
}
|
||||
|
||||
$env:POWERSHELL_TELEMETRY_OPTOUT = 1
|
||||
|
|
@ -32,10 +32,12 @@ $tokens = @(
|
|||
}
|
||||
)
|
||||
|
||||
function unlockbw {
|
||||
function unlockbw
|
||||
{
|
||||
$env:BW_SESSION = "$(bw unlock --raw)"
|
||||
|
||||
foreach ($token in $tokens) {
|
||||
foreach ($token in $tokens)
|
||||
{
|
||||
Set-Variable -Name $token.name -Value $(bw get password $token.value) -Scope script
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue