From a64226d33b9904fe95c76adb56174234501e86aa Mon Sep 17 00:00:00 2001 From: Jonas Smedegaard Date: Mon, 22 Nov 2010 18:48:42 +0100 Subject: Add sample sms app: phone. --- sms.d/phone | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100755 sms.d/phone (limited to 'sms.d') diff --git a/sms.d/phone b/sms.d/phone new file mode 100755 index 0000000..86c1eba --- /dev/null +++ b/sms.d/phone @@ -0,0 +1,28 @@ +#!/bin/sh + +# if an error occurs, break immediately +set -e + +# Variables from Kannel sms gateway +sms_from="$SMS_PHONE" +sms_to="$1" +app="$2" +shift 2 +msg="$*" + +# Settings for the "mail" outgoing email command +export smtp=mail.bitbase.dk +export from=hp@fossasia.org +export sender="$from" + +# Check keyword and break after processing if it matches +case "$app" in + phone) + cat <