Skip to content

aos clipboard

Read and write the system clipboard

9 commands. Run aos clipboard --help for the same list from the binary, or see every group.

Read and write the system clipboard as text. copy takes words or stdin, paste prints to stdout, so both sit naturally in a pipeline. To react to clipboard changes, use aos watch clipboard.

Copy stdin, or the given words, to the clipboard

Under WSL / SSH: runs on the Windows host (the machine with the screen). How the host works

Terminal window
aos clipboard copy [text...]
Terminal window
echo hello | aos clipboard copy
aos clipboard copy "some text"

List the texts the history recorder saw, newest first

Under WSL / SSH: runs on the Windows host (the machine with the screen). How the host works

Terminal window
aos clipboard history [--limit=<n>] [--json]
flag values meaning
--limit <n> Optional
--json Optional
Terminal window
aos clipboard history
aos clipboard history --limit=5 --json

Delete the recorded clipboard history

Under WSL / SSH: runs on the Windows host (the machine with the screen). How the host works

Terminal window
aos clipboard history clear
Terminal window
aos clipboard history clear

Print history entry <n> (1 is the newest)

Under WSL / SSH: runs on the Windows host (the machine with the screen). How the host works

Terminal window
aos clipboard history get <n>
flag values meaning
<n> Required positional argument
Terminal window
aos clipboard history get 2

Put history entry <n> back on the clipboard (1 is the newest)

Under WSL / SSH: runs on the Windows host (the machine with the screen). How the host works

Terminal window
aos clipboard history restore <n>
flag values meaning
<n> Required positional argument
Terminal window
aos clipboard history restore 2

Start recording clipboard history in the background (opt-in; ask the person first)

Under WSL / SSH: runs on the Windows host (the machine with the screen). How the host works

Terminal window
aos clipboard history start
Terminal window
aos clipboard history start

Say whether the history recorder is running and how much it holds

Under WSL / SSH: runs on the Windows host (the machine with the screen). How the host works

Terminal window
aos clipboard history status [--json]
flag values meaning
--json Optional
Terminal window
aos clipboard history status

Stop the clipboard history recorder (the history is kept)

Under WSL / SSH: runs on the Windows host (the machine with the screen). How the host works

Terminal window
aos clipboard history stop
Terminal window
aos clipboard history stop

Print the clipboard to stdout

Under WSL / SSH: runs on the Windows host (the machine with the screen). How the host works

Terminal window
aos clipboard paste
Terminal window
aos clipboard paste > note.txt