wpass: enter qutebrowser insert mode befor autotype

This commit is contained in:
Leonardo Eugênio 2023-02-26 15:44:32 -03:00
parent 9ecae78687
commit 007895fcb5

View file

@ -1,3 +1,5 @@
#!/bin/sh
_gpg-unlock _gpg-unlock
set -xe set -xe
@ -8,10 +10,9 @@ find_file() {
} }
main() { main() {
test -n "$PASSWORD_STORE_DIR" &&
test -n "$PASSWORD_STORE_DIR" && cd "$PASSWORD_STORE_DIR" ||
cd "$PASSWORD_STORE_DIR" || cd "$HOME/.password-store"
cd "$HOME/.password-store"
entry=`find_file "$@"` entry=`find_file "$@"`
@ -35,6 +36,10 @@ main() {
} }
autotype(){ autotype(){
if pgrep qutebrowser >/dev/null; then
qutebrowser ":mode-enter insert"
fi
env wtype -s 100 "$username" env wtype -s 100 "$username"
env wtype -s 100 -k tab env wtype -s 100 -k tab
env wtype -s 100 "$password" env wtype -s 100 "$password"