diff --git a/totptui/totptui.sh b/totptui/totptui.sh index 48dc748..4f1d517 100755 --- a/totptui/totptui.sh +++ b/totptui/totptui.sh @@ -84,7 +84,8 @@ TOTP_CODE=$(oathtool $OATHTOOL_ARGS "$key") #clear; echo -e "\e[31m$(figlet $TOTP_CODE)\e[0m" figlet_output=$(figlet -f slant "$TOTP_CODE") -echo $TOTP_CODE | xclip & +if [ -f /usr/bin/xclip ]; then echo $TOTP_CODE | xclip; fi +if [ -f /data/data/com.termux/files/usr/bin/termux-clipboard-set ]; then echo $TOTP_CODE | termux-clipboard-set; fi whiptail --title "TOTP-TUI" --msgbox "TOTP \"$account_name\" :\n\n$figlet_output" 14 45 exit #done