From 944924ab9545a94d50afdb6f08fbc7c5a3e4e3a7 Mon Sep 17 00:00:00 2001 From: Kroese Date: Tue, 15 Oct 2024 10:29:02 +0200 Subject: [PATCH] feat: Improve CPU detection (#145) --- src/reset.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/reset.sh b/src/reset.sh index 1a5c36f..76efec1 100644 --- a/src/reset.sh +++ b/src/reset.sh @@ -63,7 +63,8 @@ if [ -z "${CPU// /}" ] && grep -qi "model:" <<< "$CPI"; then CPU=$(echo "$CPI" | grep -m 1 -i 'model:' | cut -f 2 -d ":" | awk '{$1=$1}1' | sed 's# @.*##g' | sed s/"(R)"//g | sed 's/[^[:alnum:] ]\+/ /g' | sed 's/ */ /g') fi -CPU="${CPU// Quad core CPU/}" +CPU="${CPU// CPU/}" +CPU="${CPU// Quad core/}" CPU="${CPU// with Radeon Graphics/}" [ -z "${CPU// /}" ] && CPU="Unknown"