From 07119a70853db89d2bb583acbb99ec910d7d1964 Mon Sep 17 00:00:00 2001 From: Anjandev Momi Date: Tue, 7 Jul 2020 21:27:08 -0700 Subject: [PATCH] make dmenus with contact names case insensitive Signed-off-by: Miles Alan --- scripts/modem/sxmo_modemdial.sh | 2 +- scripts/modem/sxmo_modemtext.sh | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/scripts/modem/sxmo_modemdial.sh b/scripts/modem/sxmo_modemdial.sh index 7ff2fac..5cf5b89 100755 --- a/scripts/modem/sxmo_modemdial.sh +++ b/scripts/modem/sxmo_modemdial.sh @@ -20,7 +20,7 @@ dialmenu() { NUMBER="$( printf %b "Close Menu\n$CONTACTS" | grep . | - sxmo_dmenu_with_kb.sh -l 10 -p Number -c -fn Terminus-20 + sxmo_dmenu_with_kb.sh -l 10 -p Number -c -fn Terminus-20 -i )" echo "$NUMBER" | grep "Close Menu" && kill -9 0 diff --git a/scripts/modem/sxmo_modemtext.sh b/scripts/modem/sxmo_modemtext.sh index 1334a23..7c1b409 100755 --- a/scripts/modem/sxmo_modemtext.sh +++ b/scripts/modem/sxmo_modemtext.sh @@ -50,7 +50,7 @@ sendtextmenu() { NUMBER="$( printf %b "\nCancel\n$(sxmo_contacts.sh)" | awk NF | - sxmo_dmenu_with_kb.sh -p "Number" -fn "Terminus-20" -l 10 -c | + sxmo_dmenu_with_kb.sh -p "Number" -fn "Terminus-20" -l 10 -c -i | cut -d: -f1 | tr -d -- '-+ ' )" @@ -87,7 +87,7 @@ main() { sxmo_contacts.sh | grep -m1 "$NUM" | xargs -IL echo "L logfile" done )" - CONTACTIDANDNUM="$(printf %b "$ENTRIES" | dmenu -p Texts -c -fn Terminus-20 -l 10)" + CONTACTIDANDNUM="$(printf %b "$ENTRIES" | dmenu -p Texts -c -fn Terminus-20 -l 10 -i)" echo "$CONTACTIDANDNUM" | grep "Close Menu" && exit 1 echo "$CONTACTIDANDNUM" | grep "Send a Text" && sendtextmenu && exit 1 tailtextlog "$(echo "$CONTACTIDANDNUM" | cut -d: -f1)"