mirror of
https://github.com/dylanaraps/neofetch.git
synced 2025-12-14 12:37:16 +00:00
General: Make to_ functions print the error first
This commit is contained in:
8
neofetch
8
neofetch
@@ -2374,6 +2374,9 @@ display_image() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
to_ascii() {
|
to_ascii() {
|
||||||
|
# Log the error.
|
||||||
|
err "$1"
|
||||||
|
|
||||||
# This function makes neofetch fallback to ascii mode.
|
# This function makes neofetch fallback to ascii mode.
|
||||||
image_backend="ascii"
|
image_backend="ascii"
|
||||||
|
|
||||||
@@ -2382,17 +2385,14 @@ to_ascii() {
|
|||||||
|
|
||||||
# Set cursor position next image/ascii.
|
# Set cursor position next image/ascii.
|
||||||
printf "%b" "\033[${lines:-0}A\033[9999999D"
|
printf "%b" "\033[${lines:-0}A\033[9999999D"
|
||||||
|
|
||||||
# Log the error.
|
|
||||||
err "$1"
|
|
||||||
}
|
}
|
||||||
|
|
||||||
to_off() {
|
to_off() {
|
||||||
# This function makes neofetch fallback to off mode.
|
# This function makes neofetch fallback to off mode.
|
||||||
|
err "$1"
|
||||||
image_backend="off"
|
image_backend="off"
|
||||||
text_padding=
|
text_padding=
|
||||||
zws=
|
zws=
|
||||||
err "$1"
|
|
||||||
}
|
}
|
||||||
|
|
||||||
# SCREENSHOT
|
# SCREENSHOT
|
||||||
|
|||||||
Reference in New Issue
Block a user