Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/master'
Browse files Browse the repository at this point in the history
Conflicts:
	core.py
	core_test.py
  • Loading branch information
oau committed Dec 15, 2012
2 parents 932e1fe + f735b7a commit 5e54a05
Show file tree
Hide file tree
Showing 6 changed files with 200 additions and 175 deletions.
36 changes: 19 additions & 17 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,20 @@
# smskrupp

A project using [gammu](https://github.com/gammu/gammu) to handle sms lists.
smskrupp **implements SMS lists** on top of [gammu](https://github.com/gammu/gammu). Gammu does all the lower-level talking to the modem.

It has a command-line interface and a Web interface for list management.

## Usage

Use the `smskrupp` command to manage groups:

$ ./smskrupp add-group test t
$ ./smskrupp add-member 0731234567 member1 test
$ ./smskrupp add-member 0731234568 member2 test
$ ./smskrupp set-sender 0731234567 test
$ ./smskrupp list-members test

Now if you have gammu-smsd set up correctly you should be able to send a message from 0731234567 to the phone you've setup with gammu and it will deliver to all members in the group.

## Setup

Expand All @@ -14,32 +28,20 @@ If you want the webapp you also need:

# apt-get install python-bcrypt python-flask

Setting up the db:
Setting up the sqlite database:

$ cat sql/*.sql | sqlite3 smskrupp.db
$ cat sql/*.sql | sqlite3 smskrupp.db && cat sql/*.sql | sqlite3 smskrupp-test.db

Create the config file:

$ cp config.py.default config.py

Edit the config file so it points to the correct places.
Edit the config file so it points to the correct locations.

For gammu to work you also need a gammu-smsdrc, there is an example file in the doc/ directory.

## Usage

use smskrupp command to manage groups:

$ smskrupp add-group test t
$ smskrupp add-member 0731234567 member1 test
$ smskrupp add-member 0731234568 member2 test
$ smskrupp set-sender 0731234567 test
$ smskrupp list-members test

Now if you have gammu-smsd setup correctly you should be able to send a message from 0731234567 to the phone you've setup with gammu and it will deliver to all members in the group.

## Tests

If your config.py points to a test-db and a test-smsdrc, simply run
If your config.py points to a test-db and a test-smsdrc -- this is the default configuration -- simply run:

$ nosetests
3 changes: 2 additions & 1 deletion config.py.default
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
class Config:
db = 'smskrupp.db'
smsdrc = '/etc/gammu-smsdrc'
test_db = 'tmp.db'
test_db = 'smskrupp-test.db'
test_smsdrc = 'test-gammu-smsdrc'
send_prefix='#'
admin_prefix='/'
log = 'smskrupp.log'
default_phone = 'phone1'
Expand Down
Loading

0 comments on commit 5e54a05

Please sign in to comment.