From f7dc4441fc5f12cd0051f60f9cdada6adcdf7d27 Mon Sep 17 00:00:00 2001 From: Andrew Titmuss Date: Tue, 17 Oct 2017 23:13:36 +1100 Subject: [PATCH] gpu_driver: Add macOS (Nvidia) support --- config/config.conf | 2 +- neofetch | 7 +++++++ 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/config/config.conf b/config/config.conf index e43f89f5..f0d7cdb9 100644 --- a/config/config.conf +++ b/config/config.conf @@ -26,7 +26,7 @@ print_info() { info "GPU" gpu info "Memory" memory - # info "GPU Driver" gpu_driver # Linux only + # info "GPU Driver" gpu_driver # Linux/macOS only # info "CPU Usage" cpu_usage # info "Disk" disk # info "Battery" battery diff --git a/neofetch b/neofetch index c5135ea4..5b561a73 100755 --- a/neofetch +++ b/neofetch @@ -2280,6 +2280,13 @@ get_gpu_driver() { '/Display|3D|VGA/{nr[NR+2]}; NR in nr {printf $2 ", "}')" gpu_driver="${gpu_driver%, }" ;; + "Mac OS X") + if [[ "$(kextstat | grep "GeForceWeb")" != "" ]]; then + gpu_driver="Nvidia Web Driver" + else + gpu_driver="macOS Default Graphics Driver" + fi + ;; esac }