aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRasmus Steinke <rasi@xssn.at>2015-11-14 05:59:33 +0100
committerRasmus Steinke <rasi@xssn.at>2015-11-14 05:59:33 +0100
commit4553cc9946c7336376c8b6afcf44d199891dc268 (patch)
tree29187cb8def4583b455eb5a0b62e08f0551e9686
parent6ba678b85df274465304ba314b1b288065539751 (diff)
downloadrofi-pass-4553cc9946c7336376c8b6afcf44d199891dc268.tar.gz
add missing options
-rwxr-xr-xrofi-pass19
1 files changed, 15 insertions, 4 deletions
diff --git a/rofi-pass b/rofi-pass
index e08c7fd..e1951e7 100755
--- a/rofi-pass
+++ b/rofi-pass
@@ -118,6 +118,15 @@ viewEntry () {
}
generatePass () {
+ askGen () {
+ askGenMenu=$(echo -e "Yes\nNo" | rofi -dmenu -p "Generate new Password for ${selected_password}? > ")
+ if [[ $askGenMenu == "Yes" ]]; then
+ true
+ elif [[ $askGenMenu == "No" ]]; then
+ generatePass
+ fi
+ }
+
checkIfPass
symbols=$(echo -e "0 Cancel\n---\n1 Yes\n2 No" | rofi -dmenu -p "Use Symbols? > ")
if [[ $symbols == "0 Cancel" ]]; then mainMenu;
@@ -126,6 +135,7 @@ generatePass () {
fi
HELP="<span color='$help_color'>Enter Number or hit Enter to use default length</span>"
length=$(echo -e "" | rofi -dmenu -mesg "${HELP}" -p "Password length? (Default: ${passlength}) > ")
+ askGen
if [[ $length == "" ]]; then pass generate ${symbols} -i "$selected_password" "${passlength}" > /dev/null;
else pass generate ${symbols} -i "$selected_password" "${length}" > /dev/null;
fi
@@ -149,7 +159,6 @@ ${line3}</span>"
-kb-custom-6 "${copy_pass}" \
-kb-custom-7 "${show}" \
-kb-custom-8 "${copy_url}" \
- -kb-custom-9 "${edit}" \
-kb-custom-13 "${type_menu}" \
-kb-custom-14 "${action_menu}" \
-kb-custom-15 "${copy_menu}" \
@@ -198,9 +207,10 @@ ${line3}</span>"
helpMenu () {
help=$(echo -e "${type_user}: Type User
+${autotype}: Autotype
+${type_user}: Type Username
${type_pass}: Type Password
${type_menu}: Type Custom Field
-${autotype}: Autotype
---
${copy_name}: Copy Username
${copy_pass}: Copy Password
@@ -233,10 +243,11 @@ copyMenu () {
actionMenu () {
checkIfPass
- action=$(echo -e "1 Move Password File\n2 Delete Password File\n3 Generate New Password" | rofi -dmenu -p "Choose Action > ")
+ action=$(echo -e "1 Move Password File\n2 Delete Password File\\n3 Edit Password File\n4 Generate New Password" | rofi -dmenu -p "Choose Action > ")
if [[ ${action} == "1 Move Password File" ]]; then manageEntry move;
elif [[ ${action} == "2 Delete Password File" ]]; then manageEntry delete;
- elif [[ ${action} == "3 Generate New Password" ]]; then generatePass;
+ elif [[ ${action} == "4 Edit Password File" ]]; then manageEntry edit;
+ elif [[ ${action} == "4 Generate New Password" ]]; then generatePass;
elif [[ ${action} == "" ]]; then exit
fi
}