summaryrefslogtreecommitdiffstats
path: root/.bin/oath
blob: 7444993027678904ef2b7766ac68c96715119033 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
#!/bin/sh

if [[ $1 ]]; then
    PASS=$(oathtool -b --totp $(pass show "oath/$1"))
    printf $PASS | wl-copy
    echo "pass: $PASS"
    echo "Password should be in your clipboard!"
else
    echo "Usage: oath <pass>"
    echo "Available pass:"
    pass oath
fi