From 580b5fd3f0d76121d29708fc93a413519103b48a Mon Sep 17 00:00:00 2001 From: Dylan Araps Date: Sat, 1 Oct 2016 11:12:29 +1000 Subject: [PATCH] Neofetch no longer clears the screen in ascii/off modes --- neofetch | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/neofetch b/neofetch index 9a743aaf..058a97a7 100755 --- a/neofetch +++ b/neofetch @@ -3121,7 +3121,10 @@ main() { trap 'printf "\033[?25h"' EXIT # Clear the screen - clear + case "$image" in + "ascii" | "off") ;; + *) clear ;; + esac # Hide the cursor and disable line wrap printf "\033[?25l\033[?7l" @@ -3142,8 +3145,14 @@ main() { displayimage fi - # Move cursor to the top - printf "\033[0H" + printf "\033[$((${lines:-0} - 4))A" + printf "\0337" + + # Move cursor to top of ascii art + case "$image" in + "ascii" | "off") printf "\0338" ;; + *) printf "\033[0H" ;; + esac # Print the info printinfo