mirror of
https://github.com/dylanaraps/neofetch.git
synced 2025-12-22 11:39:53 +00:00
Reduce read count to 1
This commit is contained in:
8
neofetch
8
neofetch
@@ -2283,15 +2283,11 @@ getimage () {
|
||||
|
||||
else
|
||||
printf "%b%s" "\033[14t\033[c"
|
||||
read_flags="-d c"
|
||||
fi
|
||||
|
||||
# The escape code above prints the output AFTER the prompt so this
|
||||
# loop below reads it as input. wtf xterm / terminology
|
||||
if [ "$image_backend" == "tycat" ]; then
|
||||
read -t 1 -s -r term_size
|
||||
else
|
||||
read -t 1 -d c -s -r term_size
|
||||
fi
|
||||
read -t 1 ${read_flags} -s -r term_size
|
||||
stty echo
|
||||
|
||||
# Split the string
|
||||
|
||||
Reference in New Issue
Block a user