Using expect to check/navigate to correct menu and send desired cmd input After update of Yubikey-manager etc, pin code popup window appears... that make the script to fail
(Default pin are used in this example)
#!/usr/bin/expect -f
set prompt "gpg/card\>"
set keyprompt "\\? "
eval spawn gpg2 --card-edit
expect "Yubico Yubikey"
expect $prompt
send -- "admin\r"
expect $prompt
send -- "generate\r"
expect "Make off-card backup of encryption key"
send -- "n\r"
expect "PIN:"
send -- "123456"
# ..... and continue
Any input how it should be solved?
How to disable pin code popup window?