New backup 2026-01-04 17:30:01
This commit is contained in:
parent
69b6bc50a0
commit
b76ed00dc0
1 changed files with 7 additions and 14 deletions
|
|
@ -11,26 +11,19 @@ function btstatus(){
|
||||||
device_icon="$(bluetoothctl info ${m} | grep 'Icon: ' | sed 's/.*Icon: //')"
|
device_icon="$(bluetoothctl info ${m} | grep 'Icon: ' | sed 's/.*Icon: //')"
|
||||||
case "${device_icon}" in
|
case "${device_icon}" in
|
||||||
"input-mouse")
|
"input-mouse")
|
||||||
device_icon=""
|
device_icon="";;
|
||||||
;;
|
|
||||||
"phone")
|
"phone")
|
||||||
device_icon=""
|
device_icon="";;
|
||||||
;;
|
|
||||||
"input-keyboard")
|
"input-keyboard")
|
||||||
device_icon=""
|
device_icon="";;
|
||||||
;;
|
|
||||||
"input-gaming")
|
"input-gaming")
|
||||||
device_icon=""
|
device_icon="";;
|
||||||
;;
|
|
||||||
"audio-headphones")
|
"audio-headphones")
|
||||||
device_icon=""
|
device_icon="";;
|
||||||
;;
|
|
||||||
"audio-headset")
|
"audio-headset")
|
||||||
device_icon=""
|
device_icon="";;
|
||||||
;;
|
|
||||||
"computer")
|
"computer")
|
||||||
device_icon=""
|
device_icon="";;
|
||||||
;;
|
|
||||||
esac
|
esac
|
||||||
device_json=$( jq -n --arg name "${device_name}" --arg connected "${device_connected}" --arg icon "${device_icon}" --arg address "${m}" '{name: $name, connected: $connected, icon: $icon, address: $address}')
|
device_json=$( jq -n --arg name "${device_name}" --arg connected "${device_connected}" --arg icon "${device_icon}" --arg address "${m}" '{name: $name, connected: $connected, icon: $icon, address: $address}')
|
||||||
device_json_array+=("${device_json}")
|
device_json_array+=("${device_json}")
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue