some minor cleanup of issues detected by shellcheck after applying the patch: 'modemmonitor: use dbus-monitor'

master
Maarten van Gompel 4 years ago
parent 1e00b72d90
commit e11d3aaea3
  1. 5
      scripts/modem/sxmo_modemmonitor.sh

@ -1,5 +1,4 @@
#!/usr/bin/env sh #!/usr/bin/env sh
TIMEOUT=3
LOGDIR="$XDG_CONFIG_HOME"/sxmo/modem LOGDIR="$XDG_CONFIG_HOME"/sxmo/modem
NOTIFDIR="$XDG_CONFIG_HOME"/sxmo/notifications NOTIFDIR="$XDG_CONFIG_HOME"/sxmo/notifications
trap "gracefulexit" INT TERM trap "gracefulexit" INT TERM
@ -127,12 +126,12 @@ checkfornewtexts() {
mainloop() { mainloop() {
checkformissedcalls checkformissedcalls
dbus-monitor --system "interface='org.freedesktop.ModemManager1.Modem.Voice',type='signal',member='CallAdded'" | \ dbus-monitor --system "interface='org.freedesktop.ModemManager1.Modem.Voice',type='signal',member='CallAdded'" | \
while read line; do while read -r; do
checkforincomingcalls checkforincomingcalls
checkformissedcalls checkformissedcalls
done & done &
dbus-monitor --system "interface='org.freedesktop.ModemManager1.Modem.Messaging',type='signal',member='Added'" | \ dbus-monitor --system "interface='org.freedesktop.ModemManager1.Modem.Messaging',type='signal',member='Added'" | \
while read line; do while read -r; do
checkfornewtexts checkfornewtexts
done & done &
wait wait

Loading…
Cancel
Save