Created
December 18, 2019 08:21
-
-
Save hkupty/54a445081ff76abab48a7136af125f86 to your computer and use it in GitHub Desktop.
Select yubikey oath on rofi - so I don't have to go to the terminal
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
set -euo pipefail | |
ykman info > /dev/null | |
SELECTED=$(ykman oath list | rofi -dmenu) | |
if [ -n "${SELECTED}" ]; then | |
ykman oath code ${SELECTED} | awk '{ print $NF }' | xsel -b | |
fi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment