mirror of
https://github.com/js0ny/dotfiles.git
synced 2025-12-21 08:43:00 +00:00
feat(zsh): Finished reorganise zsh with a same entry point for all platforms
This commit is contained in:
parent
bd5ca49c3e
commit
2b21b63a13
22 changed files with 503 additions and 369 deletions
|
|
@ -1,3 +1,10 @@
|
|||
# $DOTFILES/platforms/wsl/winterop.zsh
|
||||
# Sourced by $DOTFILES/platforms/wsl/zshrc 在 $DOTFILES/platforms/wsl/zshrc 中被引用
|
||||
|
||||
# Defines the interop commands between WSL and Windows
|
||||
|
||||
export FILE_EXPLORER="dopus.exe" # Directory Opus
|
||||
|
||||
alias clip="clip.exe"
|
||||
alias xclip="clip.exe"
|
||||
alias paste='pwsh.exe -NoProfile -Command "Get-Clipboard"'
|
||||
|
|
@ -13,3 +20,14 @@ alias diskpart="diskpart.exe"
|
|||
alias winget="winget.exe"
|
||||
alias pastew='pwsh.exe -NoProfile -Command "Get-Clipboard"'
|
||||
alias ollama="ollama.exe"
|
||||
|
||||
# WSL open
|
||||
open() {
|
||||
local target=$1
|
||||
|
||||
if command -v "$FILE_EXPLORER" > /dev/null; then
|
||||
"$FILE_EXPLORER" "$target"
|
||||
else
|
||||
command open "$target"
|
||||
fi
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue