I'm on Wayland, so use wl-copy instead of xclip. googler supports more tools: if shutil.which('xsel') is not None: copier_params = ['xsel', '-b', '-i'] elif shutil.which('xclip') is not None: copier_params = ['xclip', '-selection', 'clipboard'] elif shutil.which('wl-copy') is not None: copier_params = ['wl-copy'] elif shutil.which('termux-clipboard-set') is not None: copier_params = ['termux-clipboard-set']