[file_previewer.sh]: Get terminal dimensions if not provided
Increase usability as standalone script, not just in lf
This commit is contained in:
@ -4,8 +4,8 @@
|
||||
preview_image="/tmp/lf_preview_image.png"
|
||||
|
||||
file=$1
|
||||
width=$2
|
||||
height=$3
|
||||
width="${2:-$(tput cols)}"
|
||||
height="${3:-$(tput lines)}"
|
||||
x=$4
|
||||
y=$5
|
||||
|
||||
|
Reference in New Issue
Block a user