From be80912e5064a73bf3957bde87ccbf86b332f323 Mon Sep 17 00:00:00 2001 From: darealshinji Date: Fri, 6 May 2016 15:49:42 +0200 Subject: [PATCH] compatibility with ARM devices running FreeBSD From PR #325 by @tntc . Untested on DragonflyBSD and therefor not applied for it too. --- screenfetch-dev | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/screenfetch-dev b/screenfetch-dev index 1458de8..ae0c9d0 100755 --- a/screenfetch-dev +++ b/screenfetch-dev @@ -1031,7 +1031,9 @@ detectcpu () { else cpu="Unknown" fi - elif [[ "$distro" == "FreeBSD" || "$distro" == "DragonflyBSD" ]]; then + elif [ "$distro" == "FreeBSD" ]; then + cpu=$(dmesg | grep 'CPU:' | head -n 1 | sed -r 's/CPU: //' | sed -e 's/([^()]*)//g') + elif [ "$distro" == "DragonflyBSD" ]; then cpu=$(sysctl -n hw.model) elif [ "$distro" == "OpenBSD" ]; then cpu=$(sysctl -n hw.model | sed 's/@.*//')