diff options
Diffstat (limited to 'home/.local/bin/pbcopy')
-rwxr-xr-x | home/.local/bin/pbcopy | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/home/.local/bin/pbcopy b/home/.local/bin/pbcopy new file mode 100755 index 00000000..a804f836 --- /dev/null +++ b/home/.local/bin/pbcopy @@ -0,0 +1,11 @@ +#!/bin/sh +set -eu + +if [ -n "${SSH_CLIENT:-}" ]; then + exec pbd -c +elif [ -n "${DISPLAY:-}" ]; then + exec xsel -bi +else + echo "${0}: don't know what to do" >&2 + exit 1 +fi |