gpu_driver: Add macOS (Nvidia) support
This commit is contained in:
parent
468c49efe7
commit
f7dc4441fc
2 changed files with 8 additions and 1 deletions
|
@ -26,7 +26,7 @@ print_info() {
|
||||||
info "GPU" gpu
|
info "GPU" gpu
|
||||||
info "Memory" memory
|
info "Memory" memory
|
||||||
|
|
||||||
# info "GPU Driver" gpu_driver # Linux only
|
# info "GPU Driver" gpu_driver # Linux/macOS only
|
||||||
# info "CPU Usage" cpu_usage
|
# info "CPU Usage" cpu_usage
|
||||||
# info "Disk" disk
|
# info "Disk" disk
|
||||||
# info "Battery" battery
|
# info "Battery" battery
|
||||||
|
|
7
neofetch
7
neofetch
|
@ -2280,6 +2280,13 @@ get_gpu_driver() {
|
||||||
'/Display|3D|VGA/{nr[NR+2]}; NR in nr {printf $2 ", "}')"
|
'/Display|3D|VGA/{nr[NR+2]}; NR in nr {printf $2 ", "}')"
|
||||||
gpu_driver="${gpu_driver%, }"
|
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
|
esac
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue