cswimr/home
Archived
Template
1
0
Fork 0

fixed some logical errors

This commit is contained in:
Seaswimmer 2024-10-11 18:45:13 -04:00
parent f312a9b06a
commit aa5315906b
Signed by: cswimr
GPG key ID: A9C162E867C851FA

View file

@ -2,7 +2,7 @@ function clip {
if [[ $(uname) == "Darwin" ]];then
command pbcopy $@
elif (( "${XDG_SESSION_TYPE}" == "x11" )); then
elif [[ "${XDG_SESSION_TYPE}" == "x11" ]]; then
if (( $+commands[xsel] )); then
command xsel -ib $@
elif (( $+commands[xclip] )); then
@ -11,14 +11,14 @@ function clip {
echo "Detected X11, but xsel or xclip are not installed."
fi
elif (( -n {WAYLAND_DISPLAY} )); then
elif [[ -n "${WAYLAND_DISPLAY}" ]]; then
if (( $+commands[wl-copy] )); then
command wl-copy $@
else
echo "Detected Wayland, but wl-copy is not installed."
fi
elif (( -n {SSH_CONNECTION} )); then
elif [[ -n "${SSH_CONNECTION}" ]]; then
if (( $+commands[lemonade] )); then
command lemonade copy $@
else