dotfiles/.config/fish/functions/pbcopy.fish

10 lines
264 B
Fish

function pbcopy -d "Copy data from STDIN to the clipboard"
if type -q xclip
command xclip -selection clipboard
else if type -q xsel
command xsel --clipboard --input
else
command echo "ERROR: xclip or xsel not found"
end
end