From cba5668f6fdc05153488bfe4ca6da25e10ecb74e Mon Sep 17 00:00:00 2001 From: Bartek Pacia Date: Mon, 8 Apr 2024 21:44:46 +0100 Subject: [PATCH] ofd: even better version of the fix Co-authored-by: Carlo Sala --- plugins/macos/macos.plugin.zsh | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/plugins/macos/macos.plugin.zsh b/plugins/macos/macos.plugin.zsh index a4347005e..d7a121925 100644 --- a/plugins/macos/macos.plugin.zsh +++ b/plugins/macos/macos.plugin.zsh @@ -4,7 +4,13 @@ 0="${${(M)0:#/*}:-$PWD/$0}" # Open the current directory in a Finder window -alias ofd='open_command $PWD' +function ofd { + if (( ! $# )); then + open_command $PWD + else + open_command $@ + fi +} # Show/hide hidden files in the Finder alias showfiles="defaults write com.apple.finder AppleShowAllFiles -bool true && killall Finder"