diff options
author | Rasmus Steinke <rasi@xssn.at> | 2016-09-10 17:19:45 +0200 |
---|---|---|
committer | Rasmus Steinke <rasi@xssn.at> | 2016-09-10 17:19:45 +0200 |
commit | 41d0dbf8cae7e713687e3fcdcb2c769f27934a26 (patch) | |
tree | e5e8de4e7d0817cec658f1299278882da5810889 | |
parent | e39d291370c0f1f80699b9cdbc383cebb6ace5d0 (diff) | |
download | rofi-pass-41d0dbf8cae7e713687e3fcdcb2c769f27934a26.tar.gz |
exclude first line when generating array
-rwxr-xr-x | rofi-pass | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -252,7 +252,8 @@ Run ${default_do} with <span color='$help_color'>Enter</span>. For more help hit # generate Array of fields password_temp=$(PASSWORD_STORE_DIR="${root}" pass "$selected_password") password="${password_temp%%$'\n'*}" - pass_key_value=$(echo "${password_temp}" | awk '$1 ~ /:$/{$1=$1;print}') + fields="$(echo "${password_temp}" | tail -n +2)" + pass_key_value=$(echo "${fields}" | awk '$1 ~ /:$/{$1=$1;print}') declare -A stuff stuff["pass"]=${password} if [[ -n $pass_key_value ]]; then |