From 4b37eb2d4d6a7fe2957aabf9299d605e1b2dcde0 Mon Sep 17 00:00:00 2001 From: Luke Bratch Date: Wed, 27 Oct 2010 14:13:43 +0100 Subject: Add README file --- README | 34 ++++++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) create mode 100644 README diff --git a/README b/README new file mode 100644 index 0000000..7d1aa2a --- /dev/null +++ b/README @@ -0,0 +1,34 @@ +Usage: blasms sender-number send-date + +SMS content should be passed using stdin. + +smsparse.conf is the configuration file and should be in the format: + default SYSTEM COMMANDS + CMD1 SYSTEM COMMANDS + CMD2 SYSTEM COMMANDS + etc. + +Where SYSTEM COMMANDS can be any command to be executed. The line starting +with 'default' must be present, and is the default command in the absense of a +recognised command. CMD1, CMD2, etc. are commands which can be matched at the +start of SMSes, in order to execute commands other than the default. Macros +are available, allowing for text replacement. The macros available are: + %N - replaced with the sender-number, and attempts to set a sender name (see + below) + %n - replaced with the sender-number + %d - replaced with the send-date + %s - replaced with the SMS content + +An example smsparse.conf might be: + default echo \"SMS from %N at %d: %s\" + LS ls %s + +Sender names are looked up in phonebook.conf, which should be in the format: + NUMBER1 NAME1 + NUMBER2 NAME2 + etc. + +An example phonebook.conf might be: + +447777123456 John + +447713987654 Bill + -- cgit v1.2.3