Ease device switching in sanity_check
authorSiraaj Khandkar <siraaj@khandkar.net>
Wed, 4 Mar 2020 22:25:31 +0000 (17:25 -0500)
committerSiraaj Khandkar <siraaj@khandkar.net>
Wed, 4 Mar 2020 22:25:31 +0000 (17:25 -0500)
x2/sanity_check

index 0f028a6..97b8b82 100755 (executable)
@@ -1,8 +1,26 @@
 #! /bin/bash
 
+# wifi devices:
+#--------------
+# - T420s       : wlp3s0
+# - T570        : wlp4s0
+# - Librem 15   : wlp1s0
+# - ASUS L203M  : wlo1
+# - Dell XPS 13 : wlp0s20f3
+
+# eth devices:
+#-------------
+# - T420s             : enp0s25
+# - T570              : enp0s31f6
+# - USB CableCreation : enxa0cec8c818ab
+# - USB StarTech      : enx00133b9c9bdb
+
+ETH='enx00133b9c9bdb'
+WIFI='wlp0s20f3'
+
 ./bin/khatus \
     --dir_bin ./bin \
-    --wifi_interface wlp4s0 \
+    --wifi_interface "$WIFI" \
     --screen_brightness_device_name intel_backlight \
 | stdbuf -o L tee \
     >(stdbuf -o L ./bin/khatus_bar \
@@ -11,7 +29,7 @@
         -v GC_Interval=300 \
         -f <(./bin/khatus_gen_bar_make_status \
                 -v Status_Fmt=' E=%s%% M=%d%% P=[%s %sr %sd %st %si %sz] C=[%s %s°C %srpm] D=[%s%% %s▲ %s▼] W=[%s %s %s▲ %s▼]  E:%s:%s  B=[%s %s] *=%s%% (%s) [%s] %s°F %s ' \
-                -v Status_Args='@energy_percent,@memory_percent,@processes_count_all,@processes_count_r,@processes_count_d,@processes_count_t,@processes_count_i,@processes_count_z,@cpu_loadavg,@cpu_temp,@cpu_fan_speed,@disk_space,@disk_io_w,@disk_io_r,@net_wifi_link:wlp4s0,@net_wifi:wlp4s0,@net_io_w:wlp4s0,@net_io_r:wlp4s0,@net_iface_status:enp0s31f6,@net_addr:enp0s31f6,@bluetooth_power,@bluetooth,@backlight_percent,@volume,@mpd,@weather_temp_f,@datetime' \
+                -v Status_Args="@energy_percent,@memory_percent,@processes_count_all,@processes_count_r,@processes_count_d,@processes_count_t,@processes_count_i,@processes_count_z,@cpu_loadavg,@cpu_temp,@cpu_fan_speed,@disk_space,@disk_io_w,@disk_io_r,@net_wifi_link:${WIFI},@net_wifi:${WIFI},@net_io_w:${WIFI},@net_io_r:${WIFI},@net_iface_status:${ETH},@net_addr:${ETH},@bluetooth_power,@bluetooth,@backlight_percent,@volume,@mpd,@weather_temp_f,@datetime" \
             ) \
     ) \
     >(stdbuf -o L ./bin/khatus_monitor_energy) \
This page took 0.027772 seconds and 4 git commands to generate.