summaryrefslogtreecommitdiff
path: root/.local/bin/lps
blob: 135848d490865dcd04e704d8a32bbbdffc956f48 (plain) (blame)
1
2
3
4
5
6
7
8
9
#!/bin/sh

set -e

flags='-m color -r 300'
[ $# -eq 1 ] && flags="$flags --area=0,0,$1,$1"

uri="$(lpoptions | sed -E 's/.*device-uri=hp:([^ ]+).*/hpaio:\1/')"
chronic hp-scan -d "$uri" $flags