From fe1d0d5f7d86e0020aae55f7afbd8a9e51c2a881 Mon Sep 17 00:00:00 2001 From: Tom Ryder Date: Sun, 26 Mar 2023 13:46:14 +1300 Subject: Correct comments in rofi_pass --- rofi/bin/rofi_pass.sh | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'rofi') diff --git a/rofi/bin/rofi_pass.sh b/rofi/bin/rofi_pass.sh index 305143e7..1f768164 100644 --- a/rofi/bin/rofi_pass.sh +++ b/rofi/bin/rofi_pass.sh @@ -39,6 +39,9 @@ get_names() { LC_COLLATE=C sort -f } +# Write a password name to a shell to retrieve it, and read its first line; +# write the name safely to the shell's input rather than as an argument. +# get_password() { name=$1 [ -n "$name" ] || return @@ -53,9 +56,8 @@ get_password() { name=$(get_names | rofi -dmenu -i -only_match -p pass) || exit [ -n "$name" ] || exit -# Write the password name to a shell to retrieve it, read its first line, and -# have xdotool write that as if the keyboard; write the name safely to the -# command's input rather than as an argument. +# Retrieve the chosen password by name; check that we actually got something +# back. # password=$(get_password "$name") || exit [ -n "$password" ] || exit -- cgit v1.2.3