use awk
This commit is contained in:
parent
b9e713f9e2
commit
a73f05e388
1 changed files with 5 additions and 1 deletions
6
neofetch
6
neofetch
|
@ -2207,7 +2207,11 @@ get_cpu() {
|
|||
;;
|
||||
|
||||
"arm"* | "aarch64")
|
||||
cpu="$(lscpu | grep "Vendor ID" | sed "s/.*: *//g") $(lscpu | grep "Model name" | sed "s/.*: *//g")"
|
||||
cpu="$(lscpu | awk -F': ' '/Vendor ID/ {print $2; exit}' ) $(lscpu | awk -F': ' '/Model name/ {print $2; exit}')"
|
||||
;;
|
||||
|
||||
"riscv"*)
|
||||
cpu="$(lscpu | awk -F': ' '/uarch/ {print $2; exit}' )"
|
||||
;;
|
||||
|
||||
*)
|
||||
|
|
Loading…
Reference in a new issue