9228c43493
Make termux-clipboard-set set the clipboard to the arguments if given, and only take stdin as input if no arguments given. Closes https://github.com/termux/termux-api/issues/8
10 lines
106 B
Bash
Executable File
10 lines
106 B
Bash
Executable File
#!/bin/sh
|
|
|
|
if [ $# = 0 ]; then
|
|
TEXT=`cat -`
|
|
else
|
|
TEXT="$@"
|
|
fi
|
|
|
|
@TERMUX_API@ Clipboard --es text "$TEXT"
|