termux-api
termux-api copied to clipboard
termux-clipboard-get is null
Problem description
Is the latest android, app can not get the clipboard content after the app running in bakcend.
Steps to reproduce
- Run the following script.
termux-clipboard-set "\$"
while true; do
sleep 3
content=`termux-clipboard-get`
echo "The clipboard content is: $content"
if [ "${content:0:1}" != "\$" ]; then
termux-clipboard-set "\$ $(date)"
fi
done
- Let termux running in backend.
- The results including content like this "The clipboard content is : " Expected behavior
Some ways to read the clipboard content while termux running in backend. Additional information
- termux-api application version: latest
- termux-api package version (installed through apt): latest
- Android OS version: android 14,
- Device model: realme gt6