dotfiles/bin/passotp

8 lines
171 B
Bash
Executable file

#!/bin/bash -e
txt="$(pass otp "$(cat /tmp/passselect)")"
bak="$(xclip -o -sel c)"
xclip -sel c <<< "$txt"
xdotool key --clearmodifiers 'ctrl+v'
xclip -sel c <<< "$txt"