From 3c2fc99271c458c9c57b2dfbc090932fb45a5717 Mon Sep 17 00:00:00 2001 From: Dylan Araps Date: Fri, 23 Dec 2016 21:05:23 +1100 Subject: [PATCH 1/2] Kernel: Simplify check --- neofetch | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/neofetch b/neofetch index 75628fca..767f159d 100755 --- a/neofetch +++ b/neofetch @@ -262,7 +262,6 @@ get_model() { model="$(wmic computersystem get manufacturer,model /value)" model="${model/Manufacturer'='}" model="${model/Model'='}" - model="${model//*To Be Filled*}" ;; "Solaris") @@ -288,15 +287,13 @@ get_title() { } get_kernel() { - [[ "$os" == "MINIX" ]] && local os="BSD" - case "$kernel_shorthand" in "on") kernel="$kernel_version" ;; "off") kernel="$kernel_name $kernel_version" ;; esac # Hide kernel info if it's identical to the distro info. - if [[ "$os" == "BSD" && "$distro" == *"$kernel_name"* ]]; then + if [[ "$distro" == *"$kernel_name"* ]]; then case "$distro_shorthand" in "on" | "tiny") kernel="$kernel_version" ;; *) unset kernel ;; From 220bd852ba826b798c092094a8ea2d8a5c019b37 Mon Sep 17 00:00:00 2001 From: Dylan Araps Date: Fri, 23 Dec 2016 21:08:26 +1100 Subject: [PATCH 2/2] Kernel: Add back OS check but simplify it --- neofetch | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/neofetch b/neofetch index 767f159d..74b3a5a3 100755 --- a/neofetch +++ b/neofetch @@ -293,7 +293,7 @@ get_kernel() { esac # Hide kernel info if it's identical to the distro info. - if [[ "$distro" == *"$kernel_name"* ]]; then + if [[ "$os" =~ (BSD|MINIX) && "$distro" == *"$kernel_name"* ]]; then case "$distro_shorthand" in "on" | "tiny") kernel="$kernel_version" ;; *) unset kernel ;;