diff --git a/users/price/dots/.config/zsh/config/profile/profile/aliases.zsh b/users/price/dots/.config/zsh/config/profile/profile/aliases.zsh index dfc58547..2627df83 100644 --- a/users/price/dots/.config/zsh/config/profile/profile/aliases.zsh +++ b/users/price/dots/.config/zsh/config/profile/profile/aliases.zsh @@ -67,11 +67,6 @@ alias p="wl-paste" fi - if ! command -v open >/dev/null 2>&1 && command -v xdg-open >/dev/null 2>&1; then - alias open="xdg-open" - alias o="xdg-open" - fi - if command -v systemctl >/dev/null 2>&1; then alias sysu="systemctl --user" alias sys="systemctl" @@ -108,4 +103,4 @@ if ! alias img >/dev/null 2>&1 && command -v swappy >/dev/null 2>&1; then alias img="swappy -f -" fi -} +} \ No newline at end of file diff --git a/users/price/dots/.config/zsh/config/profile/profile/functions.zsh b/users/price/dots/.config/zsh/config/profile/profile/functions.zsh index 28b1ce5d..eeed9a72 100644 --- a/users/price/dots/.config/zsh/config/profile/profile/functions.zsh +++ b/users/price/dots/.config/zsh/config/profile/profile/functions.zsh @@ -191,3 +191,9 @@ e() { eval "${EDITOR} ${@}" fi } + +# Open file with default program and detach +o() { + local in="${@}" + xdg-open "${@}" & disown +} \ No newline at end of file