summarylogtreecommitdiffstats
path: root/authy-qrcode-helper.sh
blob: adb2a912ed1e4222b26756d228021f0694c99072 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#!/usr/bin/env bash
#
# Generate a QR code for each line of the source file.
#

SRC=$1

if [ -z $SRC ]; then
    echo 'No source file specified.'
    exit 1
fi

cat $SRC | while IFS= read -r line; do
    clear
    echo -n "$line" | qrencode -t UTF8
    read -p $"Press Enter to continue" key < /dev/tty
done