switch "$XDG_SESSION_TYPE" case wayland echo "file://$(realpath -- "$argv")" | wl-copy -t text/uri-list case x11 echo "file://$(realpath -- "$argv")" | xclip -i -selection clipboard -t text/uri-list end