From fcc1d50b542e3cf2448a0fed9d9f200a774d52bb Mon Sep 17 00:00:00 2001 From: Dylan Date: Tue, 23 Feb 2016 10:36:10 +1100 Subject: [PATCH] Shorten Mac OS X GPU output and add a comma between gpus --- fetch | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/fetch b/fetch index a2972a17..a4152b13 100755 --- a/fetch +++ b/fetch @@ -920,12 +920,9 @@ getgpu () { ;; "Mac OS X") - gpu=$( \ - system_profiler SPDisplaysDataType | \ - awk -F': ' '/^\ *Chipset Model:/ {printf $2 ", "}' | \ - awk '{ printf "%s ", $0 }' - ) + gpu=$(system_profiler SPDisplaysDataType | awk -F': ' '/^\ *Chipset Model:/ {printf $2 ", "}') gpu=${gpu//'/ $'} + gpu=${gpu%,*} ;; *"BSD")