Sync from Mac

This commit is contained in:
js0ny 2024-08-03 11:09:38 +08:00
parent 90110e8fed
commit 02ed4d20fb
11 changed files with 163 additions and 42 deletions

View file

@ -18,19 +18,19 @@ Set-PSReadLineKeyHandler -Chord "Ctrl+f" -Function ForwardWord
# Relative navigation #
# ${function:~} = { Set-Location -Path ~ } cd is better
${function:...} = { Set-Location -Path ..\.. }
${function:....} = { Set-Location -Path ..\..\.. }
${function:.....} = { Set-Location -Path ..\..\..\.. }
${function:......} = { Set-Location -Path ..\..\..\..\.. }
${function:...} = { Set-Location -Path ../.. }
${function:....} = { Set-Location -Path ../../.. }
${function:.....} = { Set-Location -Path ../../../.. }
${function:......} = { Set-Location -Path ../../../../.. }
# Absolute navigation #
${function:docs} = { Set-Location -Path ~\Documents }
${function:down} = { Set-Location -Path ~\Downloads }
${function:dt} = { Set-Location -Path ~\Desktop }
${function:mytmp} = { Set-Location -Path ~\Temp }
${function:one} = { Set-Location -Path ~\OneDrive }
${function:doku} = { Set-Location -Path ~\doku && Get-ChildItem }
${function:docs} = { Set-Location -Path ~/Documents }
${function:down} = { Set-Location -Path ~/Downloads }
${function:dt} = { Set-Location -Path ~/Desktop }
${function:mytmp} = { Set-Location -Path ~/Temp }
${function:one} = { Set-Location -Path ~/OneDrive }
${function:doku} = { Set-Location -Path ~/doku && Get-ChildItem }
### Aliases ###
@ -51,14 +51,21 @@ ${function:reload} = { Invoke-Expression $PROFILE }
${function:csi} = { dotnet script }
${function:pulldots} = { Set-Location -Path $DOTFILES && git pull }
Set-Alias "pwshcfg" "shcfg"
Set-Alias "python3" "python"
Set-Alias "pip3" "pip"
Set-Alias "py" "python"
Set-Alias "cl" "clang"
Set-Alias "cl++" "clang++"
Set-Alias "clang" "clang -std=c99"
Set-Alias "clang++" "clang++ -std=c++2b"
# Python & Conda #
Set-Alias "python3" "python"
Set-Alias "pip3" "pip"
Set-Alias "py" "python"
Set-Alias "pyact" "conda activate"
Set-Alias "pylsenv" "conda env list"
Set-Alias "pydeact" "conda deactivate"
Set-Alias "pymkenv" "conda create --name"
# Editors #
Set-Alias "v" "nvim"
@ -88,5 +95,7 @@ function cdls { param( [string] $dirname)
### Modules ###
Import-Module CompletionPredictor
# Import-Module syntax-highlighting
### Misc ###
### Misc ###