浏览代码

add Wifi 6 (802.11ac) (VHT) support

Depends on `iw`.
TODO: Cannot detect if VHT is actually being used.
b1f6c1c4 5 年之前
父节点
当前提交
2131948855
共有 1 个文件被更改,包括 4 次插入0 次删除
  1. 4 0
      neofetch

+ 4 - 0
neofetch

@@ -2659,6 +2659,8 @@ get_network() {
                         networks+="$(cat "$i/speed")"
                     else
                         networks+="Wifi"
+                        phy="$(cat "$i/phy80211/name")"
+                        (iw "$phy" info | grep -qF 'VHT Capabilities') && networks+='6'
                     fi
                     networks+=$'\n'
                 fi
@@ -2670,6 +2672,8 @@ get_network() {
             [ "$n" -gt 1 ] && network+="${n}x "
             if [ "$i" = "Wifi" ]; then
                 network+="Wifi; "
+            elif [ "$i" = "Wifi6" ]; then
+                network+="Wifi6; "
             elif [ "$i" = "-1" ]; then
                 network+="Unknown; "
             elif [ "${i%000}" = "$i" ]; then