diff --git a/home/user/.config/zsh/functions b/home/user/.config/zsh/functions index 4419c76..e941451 100644 --- a/home/user/.config/zsh/functions +++ b/home/user/.config/zsh/functions @@ -54,7 +54,10 @@ mcd() { } open() { - test -e "${1}" || return 1 + if [ ! -e "${1}" ]; then + printf 'File %s not found' "${1}" >&2 + exit 1 + fi nohup xdg-open "${1}" 1>/dev/null 2>&1 & }