]> Freerunner's - dotfiles.git/commitdiff
aerc: improve keepassxc helper script
authorAndre Ramnitz <tux.rising@gmail.com>
Wed, 17 Jan 2024 23:26:43 +0000 (00:26 +0100)
committerAndre Ramnitz <tux.rising@gmail.com>
Sun, 18 Aug 2024 16:18:53 +0000 (18:18 +0200)
config/aerc/scripts/wait-for-creds.sh

index 7ab4f10..834c67e 100755 (executable)
@@ -1,8 +1,14 @@
 #!/bin/sh
 
+if [ ! "$(pidof keepassxc)" ]; then
+    echo "KeepassXC not running";
+    exit 1
+fi
+
 secret-tool lookup "$1" "$2"
 # wait until the password is available
 while [ $? != 0 ]; do
        secret-tool lookup "$1" "$2"
+       sleep 5
 done