From ed3a47d16963fdf47a9259b281977f54f4c5dee2 Mon Sep 17 00:00:00 2001 From: Dylan Araps Date: Sun, 8 Jan 2017 07:39:41 +1100 Subject: [PATCH] General: Swap some math to simpler syntax --- neofetch | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/neofetch b/neofetch index 11f5d252..8dea7c82 100755 --- a/neofetch +++ b/neofetch @@ -1041,7 +1041,7 @@ get_gpu() { fi prin "${subtitle}${gpu_num}" "$gpu" - gpu_num="$((gpu_num+=1))" + ((++gpu_num)) done return @@ -1952,7 +1952,7 @@ get_ascii() { line="${line//\$\{??\}}" line="${line//\\\\/\\}" ((${#line} > ascii_length)) && ascii_length="${#line}" - lines="$((lines+=1))" + ((++lines)) done < "$ascii" # Colors. @@ -2437,7 +2437,7 @@ prin() { printf "%b\n" "${text_padding:+\033[${text_padding}C}${zws}${string}${reset} " # Calculate info height. - info_height="$((info_height+=1))" + ((++info_height)) # Log that prin was used. prin=1 @@ -2456,7 +2456,7 @@ get_line_break() { printf "%s\n" "${zws} " # Calculate info height. - info_height="$((info_height+=1))" + ((++info_height)) # Tell info() that we printed manually. prin=1