From 921b578b407629e7e78ba088f184e723c43c3fe1 Mon Sep 17 00:00:00 2001 From: Patrick Csikos Date: Mon, 8 Jul 2024 19:22:51 -0400 Subject: [PATCH] fix(run-davinci): Check for Nvidia GPU first (#101) Right now, this shouldn't actually have a big effect on things, since we're not applying any Nvidia-specific workarounds in `run-davinci` at the moment, but in the future, if we need to for e.g. laptops with Intel iGPUs + Nvidia dGPUs, we'll want to check for the Nvidia GPU first. --- system_files/usr/bin/run-davinci | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/system_files/usr/bin/run-davinci b/system_files/usr/bin/run-davinci index bfa8fef..6d4ff38 100755 --- a/system_files/usr/bin/run-davinci +++ b/system_files/usr/bin/run-davinci @@ -8,12 +8,12 @@ export QT_QPA_PLATFORM=xcb gpu_type="" get_gpu_type () { - if [[ -n $(glxinfo -B | grep -i AMD) ]]; then + if [[ -n $(glxinfo -B | grep -i nvidia) ]]; then + gpu_type="nvidia" + elif [[ -n $(glxinfo -B | grep -i AMD) ]]; then gpu_type="amd" elif [[ -n $(glxinfo -B | grep -i Intel) ]]; then gpu_type="intel" - elif [[ -n $(glxinfo -B | grep -i nvidia) ]]; then - gpu_type="nvidia" fi }