aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/home/.local/bin/wqr
blob: 09186ff611b575c5de44023f83624d7a557f061b (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
#!/usr/bin/env sh

if [ -z "$1" ]; then
    text=$(xclip -o -selection clipboard)
elif [ "$1" = "-" ]; then
    read -r text
else
    text="$1"
fi

printf '%s' "$text" | qrencode -t SVG -o - | feh - --conversion-timeout 1