diff options
author | Rasmus Steinke <rasi@xssn.at> | 2018-03-28 21:58:25 +0200 |
---|---|---|
committer | Rasmus Steinke <rasi@xssn.at> | 2018-03-28 21:59:00 +0200 |
commit | 3ce676fefc94ef8e047a7c039627fdcc9b43b262 (patch) | |
tree | 5f5a2423c0cc42c920e95222f4d11bd8de7bab81 | |
parent | 6ba5dfb2140c1148fdebfae35f45a2a893feb895 (diff) | |
download | rofi-pass-3ce676fefc94ef8e047a7c039627fdcc9b43b262.tar.gz |
add option to (not) open new password entries in editor, fixes #122
-rw-r--r-- | config.example | 6 | ||||
-rwxr-xr-x | rofi-pass | 6 |
2 files changed, 10 insertions, 2 deletions
diff --git a/config.example b/config.example index 24f1f26..bac714a 100644 --- a/config.example +++ b/config.example @@ -59,7 +59,11 @@ help_color="#4872FF" # Possible options: primary, clipboard, both clip=primary -# Options for generating new password entries +## Options for generating new password entries + +# open new password entries in editor +open_new_pass="true" + # default_user is also used for password files that have no user field. #default_user="${ROFI_PASS_DEFAULT_USER-$(whoami)}" #default_user2=mary_ann @@ -732,7 +732,11 @@ Type name, make sure it is unique" "${pw}" "---" "${USERNAME_field}: ${user}") - printf '%s\n' "${pass_content[@]}" | PASSWORD_STORE_DIR="${root}" pass insert -m "${group}/${name}" > /dev/null && PASSWORD_STORE_DIR="${root}" pass edit "${group}/${name}" + printf '%s\n' "${pass_content[@]}" | PASSWORD_STORE_DIR="${root}" pass insert -m "${group}/${name}" > /dev/null + if [[ $edit_new_pass == "true" ]] + then + PASSWORD_STORE_DIR="${root}" pass edit "${group}/${name}" + fi fi fi } |