Added the ability to have spaces in password names
This commit is contained in:
parent
257086fc08
commit
94827d7696
|
@ -2,16 +2,16 @@
|
||||||
|
|
||||||
folder="$(ls ~/.password-store/ | sed -e 's/\.gpg$//' | fuzzel -d)"
|
folder="$(ls ~/.password-store/ | sed -e 's/\.gpg$//' | fuzzel -d)"
|
||||||
|
|
||||||
if [ -z $folder ];
|
if [ -z "$folder" ];
|
||||||
then
|
then
|
||||||
exit
|
exit
|
||||||
fi
|
fi
|
||||||
|
|
||||||
choice="$(ls ~/.password-store/$folder | sed -e 's/\.gpg$//' | fuzzel -d)"
|
choice="$(ls ~/.password-store/$folder | sed -e 's/\.gpg$//' | fuzzel -d)"
|
||||||
|
|
||||||
if [ -z $choice ];
|
if [ -z "$choice" ];
|
||||||
then
|
then
|
||||||
exit
|
exit
|
||||||
fi
|
fi
|
||||||
|
|
||||||
wtype -d 10 "$(pass show $folder/$choice | head -n1)"
|
wtype -d 10 "$(pass show "$folder/$choice" | head -n1)"
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
folder="$(ls ~/.password-store/ | sed -e 's/\.gpg$//' | fuzzel -d -i)"
|
folder="$(ls ~/.password-store/ | sed -e 's/\.gpg$//' | fuzzel -d -i)"
|
||||||
|
|
||||||
if [ -z $folder ];
|
if [ -z "$folder" ];
|
||||||
then
|
then
|
||||||
exit
|
exit
|
||||||
else
|
else
|
||||||
|
@ -11,10 +11,10 @@ fi
|
||||||
|
|
||||||
choice="$(ls ~/.password-store/$folder | sed -e 's/\.gpg$//' | fuzzel -d -i)"
|
choice="$(ls ~/.password-store/$folder | sed -e 's/\.gpg$//' | fuzzel -d -i)"
|
||||||
|
|
||||||
if [ -z $choice ];
|
if [ -z "$choice" ];
|
||||||
then
|
then
|
||||||
exit
|
exit
|
||||||
else
|
else
|
||||||
wtype -d 10 $(pass show $folder/$choice | grep username: | sed 's/username: //')
|
wtype -d 10 $(pass show "$folder/$choice" | grep username: | sed 's/username: //')
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue