Fixed setup not saving password

This commit is contained in:
JeremyStarTM 2022-08-15 13:57:15 +02:00
parent 47d6b0d062
commit ecc1334bd3

View file

@ -341,8 +341,8 @@ function doSSHSetup() {
echo -n "Is this information correct [y/N]? " echo -n "Is this information correct [y/N]? "
read -r SOSSSH_ENTRY_CONFIRMATION read -r SOSSSH_ENTRY_CONFIRMATION
if [ "$SOSSSH_ENTRY_CONFIRMATION" == "y" ] || [ "$SOSSSH_ENTRY_CONFIRMATION" == "Y" ]; then if [ "$SOSSSH_ENTRY_CONFIRMATION" == "y" ] || [ "$SOSSSH_ENTRY_CONFIRMATION" == "Y" ]; then
export "SOSSSH_ENTRY_PASSWD="
echo -e "# This file has been generated by sos-ssh by using setup\nSOSSSH_HOST=$SOSSSH_ENTRY_HOST\nSOSSSH_PORT=$SOSSSH_ENTRY_PORT\nSOSSSH_USERNAME=$SOSSSH_ENTRY_USERNAME\nSOSSSH_PASSWD=$SOSSSH_ENTRY_PASSWD" &> "$HOME/.sostools/ssh/sos-ssh.conf.d/sshsetup.conf" echo -e "# This file has been generated by sos-ssh by using setup\nSOSSSH_HOST=$SOSSSH_ENTRY_HOST\nSOSSSH_PORT=$SOSSSH_ENTRY_PORT\nSOSSSH_USERNAME=$SOSSSH_ENTRY_USERNAME\nSOSSSH_PASSWD=$SOSSSH_ENTRY_PASSWD" &> "$HOME/.sostools/ssh/sos-ssh.conf.d/sshsetup.conf"
export "SOSSSH_ENTRY_PASSWD="
else else
export "SOSSSH_ENTRY_PASSWD=" export "SOSSSH_ENTRY_PASSWD="
echo "Cancelled." echo "Cancelled."