12 lines
364 B
Bash
Executable File
12 lines
364 B
Bash
Executable File
#!/bin/bash
|
|
# Compare select terminal image viewers
|
|
# Args: <height> [images]...
|
|
runti() {
|
|
which "$1" >/dev/null &&
|
|
highlight "$*" && "$@"
|
|
}
|
|
cols="$(expr $(tput cols) / $1 / 3 \| 1)"
|
|
runti timg --rotate=exif --title --grid=${cols} -g $(tput cols)x$(expr $1 \* $cols + 4) "${@:2}"
|
|
runti viu --name -h $1 "${@:2}"
|
|
runti tiv -h $1 -c $(expr $cols + 1) "${@:2}"
|