fix: read user input from /dev/tty when piped via curl

This commit is contained in:
tinkle-community
2025-12-28 22:15:47 +08:00
parent b228412821
commit d5a2f8ef8d
+1 -1
View File
@@ -148,7 +148,7 @@ ask_clear_trading_data() {
echo ""
echo -e "${BLUE}Type 'yes' to clear tables, press Enter or any other input to skip${NC}"
echo -n "Input: "
read -r confirm
read -r confirm < /dev/tty
if [ "$confirm" == "yes" ]; then
CLEAR_TRADING_DATA="yes"