From 18e3dd9665c4d2d8f61316457c860c6f28e8fbc2 Mon Sep 17 00:00:00 2001 From: Rasmus Steinke Date: Thu, 20 Aug 2015 17:36:08 +0200 Subject: [PATCH] use PASSWORD_STORE_DIR variable for all main menu actions --- rofi-pass | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/rofi-pass b/rofi-pass index 49d0e66..27922f3 100755 --- a/rofi-pass +++ b/rofi-pass @@ -35,6 +35,7 @@ else root="$HOME/.password-store" fi fi +PASSWORD_STORE_DIR="${root}" # get all password files and create an array list_passwords() { @@ -88,7 +89,7 @@ mainMenu () { fi - password_temp=$(pass "$selected_password") + password_temp=$(PASSWORD_STORE_DIR="${root}" pass "$selected_password") password=$(echo "${password_temp}" | head -1) declare -A stuff @@ -96,7 +97,7 @@ mainMenu () { _id=$(echo -e "${LINE}" | awk -F ':[[:space:]]*' '{print $1}') _val=$(echo -e "${LINE}" | awk '{sub(/:/,"")}{for (i=2; i ") + bla=$(echo -e "0 Return\n---\n$(PASSWORD_STORE_DIR="${root}" pass "$selected_password")" | _rofi -dmenu -mesg "${HELP}" -p "> ") rofi_exit=$? word=$(echo "$bla" | awk -F': ' '{print $1}') if [[ ${rofi_exit} -eq 0 ]]; then