From 6e9d3cdd415dbd8ef58f05d26a1df938280a0468 Mon Sep 17 00:00:00 2001 From: Shihaam Abdul Rahman Date: Wed, 28 Apr 2021 19:42:43 +0500 Subject: [PATCH] save password location with warning --- bml.sh | 7 +++---- savepass.sh | 2 ++ 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/bml.sh b/bml.sh index 2371ca5..b51a5ad 100755 --- a/bml.sh +++ b/bml.sh @@ -1,12 +1,11 @@ #!/bin/bash - - -#Setting intial variables -BML_URL='https://www.bankofmaldives.com.mv/internetbanking/api' +#Making cookie and credentials dir mkdir -p ~/.config/bml-cli/ mkdir -p ~/.cache/bml-cli/ +#Setting intial variables +BML_URL='https://www.bankofmaldives.com.mv/internetbanking/api' COOKIE=~/.cache/bml-cli/cookie CREDENTIALS=~/.config/bml-cli/.env diff --git a/savepass.sh b/savepass.sh index c376487..b5bfbfc 100644 --- a/savepass.sh +++ b/savepass.sh @@ -7,11 +7,13 @@ then read -p 'Do you want to save login? [y/N] ' SAVE_LOGIN if [ "$SAVE_LOGIN" = "Y" ] then + echo "Username and Password is saved in ${lightred}PAIN TEXT${reset} in $CREDENTIALS" echo "BML_USERNAME='${BML_USERNAME}'" > $CREDENTIALS echo "BML_PASSWORD='${BML_PASSWORD}'" >> $CREDENTIALS elif [ "$SAVE_LOGIN" = "y" ] then + echo "Username and Password is saved in ${lightred}PAIN TEXT${reset} in $CREDENTIALS" echo "BML_USERNAME='${BML_USERNAME}'" > $CREDENTIALS echo "BML_PASSWORD='${BML_PASSWORD}'" >> $CREDENTIALS else