10 lines
205 B
Plaintext
10 lines
205 B
Plaintext
|
#!/usr/bin/env bash
|
||
|
|
||
|
session="$(loginctl show-session "$(loginctl | grep "$(whoami)" | awk '{print $1}')" -p Type)"
|
||
|
|
||
|
if [ "$session" = "Type=x11" ]; then
|
||
|
exec xsel -b -i "$@"
|
||
|
else
|
||
|
exec wl-copy "$@"
|
||
|
fi
|