aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHari Hendaryanto <hari.hendaryanto@gmail.com>2018-09-22 12:33:28 +0700
committerHari Hendaryanto <hari.hendaryanto@gmail.com>2018-09-22 12:33:28 +0700
commit7e287251179aef8867ea4310c17971dd4517fd5d (patch)
tree7a1113d4ee086e513b71c9ca7ba9e0a26649ccbe
parent2984154565b5fdd742b96d6d8f77b30a5a0b114d (diff)
Read sms phonenumber and some lazy formating. But it's good on console :D
-rw-r--r--e3372-readsms.sh4
1 files changed, 2 insertions, 2 deletions
diff --git a/e3372-readsms.sh b/e3372-readsms.sh
index 82a1595..38d980f 100644
--- a/e3372-readsms.sh
+++ b/e3372-readsms.sh
@@ -9,6 +9,6 @@ curl -s -X POST "http://$MODEM_IP/api/sms/sms-list" -H "Cookie: $COOKIE" -H "__R
#cat modem_status.xml
-message=$(grep -r Content modem_status.xml | sed -e 's/<[^>]*>//g' | sed -e 's/^[ \t]*/\n/g')
+message=$(grep -r -E 'Phone|Content' modem_status.xml | sed -e 's/<[^>]*>//g' | sed -e 's/^[ \t]*/------\n/g')
-echo "$message\n"
+echo "$message\n------" \ No newline at end of file