From 311f355aa86a749229d3c04fcd17752c3fe9cb63 Mon Sep 17 00:00:00 2001 From: Siraaj Khandkar Date: Mon, 2 Nov 2020 04:59:30 -0500 Subject: [PATCH] Tighten bluetoothctl output matching to exclude logs --- home/lib/login_functions.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/home/lib/login_functions.sh b/home/lib/login_functions.sh index 6b0c1bc..243f15f 100644 --- a/home/lib/login_functions.sh +++ b/home/lib/login_functions.sh @@ -346,7 +346,7 @@ _bt_devs_infos() { # which bluetoothctl outputs awk '/^Device +/ {print $2}' \ | xargs -I% sh -c 'echo info % | bluetoothctl' \ - | awk '/^Device |^\t/' + | awk '/^Device |^\t[A-Z][A-Za-z0-9]+: /' } bt_devs_paired() { -- 2.20.1