Plus prefix strip numbers before storing into modem log

master
Miles Alan 5 years ago
parent e3f50e9d1b
commit 844ce9ddef
  1. 2
      scripts/modem/sxmo_modemcall.sh
  2. 2
      scripts/modem/sxmo_modemmonitor.sh
  3. 2
      scripts/modem/sxmo_modemtext.sh

@ -34,7 +34,7 @@ vid_to_number() {
mmcli -m "$(modem_n)" -o "$1" -K |
grep call.properties.number |
cut -d ':' -f2 |
tr -d ' '
tr -d ' +'
}
log_event() {

@ -50,7 +50,7 @@ checkforincomingcalls() {
mmcli -m "$(modem_n)" --voice-list-calls -o "$VOICECALLID" -K |
grep call.properties.number |
cut -d ':' -f 2 |
tr -d ' '
tr -d ' +'
)
# Log to /tmp/incomingcall to allow pickup and log into modemlog

@ -52,7 +52,7 @@ sendtextmenu() {
awk NF |
sxmo_dmenu_with_kb.sh -p "Number" -fn "Terminus-20" -l 10 -c |
cut -d: -f1 |
tr -d -- '- '
tr -d -- '-+ '
)"
echo "$NUMBER" | grep -E "^Cancel$" && exit 1
echo "$NUMBER" | grep -qE '^[+0-9]+$' || err "That doesn't seem like a valid number"

Loading…
Cancel
Save