feat(riot): conditionally RequestTTY

This commit is contained in:
2025-12-19 21:28:16 +08:00
parent bdef3b52d1
commit d283671f25
2 changed files with 7 additions and 4 deletions

View File

@@ -93,7 +93,10 @@ parse_remote() {
TRUST_SERVER=1
PORT="" # optional
USERNAME="" # optional
SSH_OPTIONS=("-o" "RequestTTY=yes" "-o" "ServerAliveInterval=60")
SSH_OPTIONS=("-o" "ServerAliveInterval=60")
if [[ -t 1 ]]; then
SSH_OPTIONS+=("-o" "RequestTTY=yes")
fi
if [[ "$RIOT_TRUST_CLIENT" == "1" ]]; then
SSH_OPTIONS+=("-o" "PermitLocalCommand=yes")
if [[ "$(get_os_type)" != "msys" ]]; then