From 6f1ed5c0b7679e5d0d09c73782550bcf9c3cf534 Mon Sep 17 00:00:00 2001 From: Dylan Date: Mon, 18 Jan 2016 17:37:00 +1100 Subject: [PATCH] Turns out other *BSD distros don't have hw.cpuspeed --- fetch | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/fetch b/fetch index c9feea5a..4455cf73 100755 --- a/fetch +++ b/fetch @@ -552,7 +552,7 @@ getcpu () { cpu="$(sysctl -n machdep.cpu.brand_string)" ;; - *"BSD") + "OpenBSD") cpu="$(sysctl -n hw.model)" cpu=${cpu/ @*/} cpu=${cpu// /} @@ -565,6 +565,10 @@ getcpu () { cpu="$cpu @ ${speed}GHz" ;; + *"BSD") + cpu="$(sysctl -n hw.model)" + ;; + "Windows") # Get cpu name cpu="$(grep -F 'model name' /proc/cpuinfo)"