Fixed var usage

This commit is contained in:
Wryn Wagner 2020-04-06 12:01:34 -06:00
parent 18f5a9022c
commit b4e3688bc2

View File

@ -109,10 +109,10 @@ elif [ "$database_type" == "postgresql" ]; then
else else
database_type=$(echo -e "mssql\npostgresql" | fzf --height="$FZF_HEIGHT"% --layout=reverse); database_type=$(echo -e "mssql\npostgresql" | fzf --height="$FZF_HEIGHT"% --layout=reverse);
if [ "$database_type" == "mssql" ]; then if [ "$database_type" == "mssql" ]; then
printf "DB_TYPE_SELECTED" "Microsoft SQL"; printf "$DB_TYPE_SELECTED" "Microsoft SQL";
mssql-cli -S "$server" -U "$user" -P "$pass"; mssql-cli -S "$server" -U "$user" -P "$pass";
elif [ "$database_type" == "postgresql" ]; then elif [ "$database_type" == "postgresql" ]; then
printf "DB_TYPE_SELECTED" "Postgres"; printf "$DB_TYPE_SELECTED" "Postgres";
PGPASSWORD="$pass" pgcli -h "$server" -U "$user" -d "$dbname"; PGPASSWORD="$pass" pgcli -h "$server" -U "$user" -d "$dbname";
fi fi
fi fi