Commit 0dff1213 authored by SomaUlte's avatar SomaUlte Committed by GitHub

apply dylanaraps' changes

parent 08276bde
...@@ -1075,11 +1075,12 @@ get_gpu() { ...@@ -1075,11 +1075,12 @@ get_gpu() {
;; ;;
*"intel"*) *"intel"*)
if [[ $(glxinfo | grep 'OpenGL renderer string: Mesa' | sed 's/ renderer.*//') = "OpenGL" ]]; then gpu="$(glxinfo | grep -F "Device:")"
gpu="$(DRI_PRIME=1 glxinfo | grep 'OpenGL renderer' | sed '0,/^.*Intel/ s//Intel/' | sed 's/(R)//' | sed 's/\(\.* (\).*//')" gpu="${gpu/*Intel/Intel}"
else gpu="${gpu/'(R)'}"
gpu="Intel Integrated Graphics" gpu="${gpu/ \(*}"
fi
[[ -z "$(trim "$gpu")" ]] && gpu="Intel Integrated Graphics"
;; ;;
*"virtualbox"*) *"virtualbox"*)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment