From 329346d460ed15bbe6fbf751c26be203ca52fde9 Mon Sep 17 00:00:00 2001 From: LER0ever Date: Sat, 27 May 2017 13:30:02 +0800 Subject: [PATCH 1/2] Model: add support for Hackintosh --- neofetch | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/neofetch b/neofetch index ea2c4e93..1a50b374 100755 --- a/neofetch +++ b/neofetch @@ -242,7 +242,13 @@ get_model() { fi ;; - "Mac OS X") model="$(sysctl -n hw.model)" ;; + "Mac OS X") + if [[ $(kextstat | grep "FakeSMC") != "" ]]; then + model="Hackintosh (SMBIOS: $(sysctl -n hw.model))" + else + model="$(sysctl -n hw.model)" + fi + ;; "iPhone OS") case "$machine_arch" in "iPad1,1") model="iPad" ;; From 0f945f9b637c33eb96fdf56029590df4466f9882 Mon Sep 17 00:00:00 2001 From: LER0ever Date: Sat, 27 May 2017 14:06:45 +0800 Subject: [PATCH 2/2] fix(style): double quote vars, remove unnecessary empty check --- neofetch | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/neofetch b/neofetch index 1a50b374..99f66bc4 100755 --- a/neofetch +++ b/neofetch @@ -243,7 +243,7 @@ get_model() { ;; "Mac OS X") - if [[ $(kextstat | grep "FakeSMC") != "" ]]; then + if [[ "$(kextstat | grep "FakeSMC")" ]]; then model="Hackintosh (SMBIOS: $(sysctl -n hw.model))" else model="$(sysctl -n hw.model)"