Forrest logo
back to the wl-copy tool

wl-copy:tldr:22e19

wl-copy: Copy for only one paste and then clear it.
$ wl-copy --paste-once "${text}"
try on your machine

The wl-copy command is used for copying text to the clipboard in the Wayland display server protocol. It is similar to the xclip command used in X Window System.

The --paste-once option is an argument passed to wl-copy to indicate that the text being copied should only be available for a single paste. This means that once the text is pasted, it will no longer be available in the clipboard.

${text} is a placeholder representing the text to be copied. It is a variable that should be replaced with the actual text you want to copy before running the command. For example, if you want to copy the text "Hello, world!", the command would be:

wl-copy --paste-once "Hello, world!"

After running this command, the text "Hello, world!" will be copied to the clipboard and will only be available for one paste operation.

This explanation was created by an AI. In most cases those are correct. But please always be careful and never run a command you are not sure if it is safe.
back to the wl-copy tool