QueManager BETA 1.0.9
- Added Cell Locking Scheduler UI improvements - Fixed change_sms_code.sh to properly exit - Added an experimental feature: Keep-alive - Added disable state for speedtest when keep-alive is active Co-Authored-By: Russel Yasol <73575327+dr-dolomite@users.noreply.github.com>
This commit is contained in:
@@ -16,18 +16,19 @@ if [ ! -c "/dev/smd7" ]; then
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Fetch all SMS messages and update the JSON file
|
||||
if ! echo "AT+CMGL=\"ALL\"" | atinout - /dev/smd7 - | jq -R -s '
|
||||
split("\n") |
|
||||
map(select(length > 0)) |
|
||||
map(
|
||||
select(startswith("+CMGL:") or (. != "OK" and . != "ERROR"))
|
||||
) |
|
||||
{messages: .}
|
||||
' > /tmp/sms_inbox.json; then
|
||||
echo '{"error": "Failed to fetch SMS messages"}'
|
||||
exit 1
|
||||
fi
|
||||
# # Fetch all SMS messages and update the JSON file
|
||||
# Disabled until the atinout bug is fixed
|
||||
# if ! echo "AT+CMGL=\"ALL\"" | atinout - /dev/smd7 - | jq -R -s '
|
||||
# split("\n") |
|
||||
# map(select(length > 0)) |
|
||||
# map(
|
||||
# select(startswith("+CMGL:") or (. != "OK" and . != "ERROR"))
|
||||
# ) |
|
||||
# {messages: .}
|
||||
# ' > /tmp/sms_inbox.json; then
|
||||
# echo '{"error": "Failed to fetch SMS messages"}'
|
||||
# exit 1
|
||||
# fi
|
||||
|
||||
# Return the contents of the JSON file
|
||||
if [ -f "/tmp/sms_inbox.json" ]; then
|
||||
|
||||
@@ -198,4 +198,4 @@ echo "Status: 400 Bad Request"
|
||||
echo "Content-Type: application/json"
|
||||
echo ""
|
||||
echo "{\"error\":\"Invalid request\"}"
|
||||
exit 1
|
||||
exit 1
|
||||
Reference in New Issue
Block a user