Browse Source
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/8android-5
Fredrik Fornwall
9 years ago
2 changed files with 7 additions and 2 deletions
@ -1,4 +1,9 @@ |
|||
#!/bin/sh |
|||
|
|||
TEXT=`cat -` |
|||
if [ $# = 0 ]; then |
|||
TEXT=`cat -` |
|||
else |
|||
TEXT="$@" |
|||
fi |
|||
|
|||
@TERMUX_API@ Clipboard --es text "$TEXT" |
|||
|
Loading…
Reference in new issue