1 2 3 4 5 6 7 8 9
#!/usr/bin/env sh name=$(bluetoothctl info | grep "Name" | sed 's/.*Name: //') if [ ! "$name" ] then echo "" else echo "" $name; fi