Add several model class definitions & migrations

Add NewPostEmail, ClaimedItemEmail, EmailThread, and Item to models.py,
along with the database migration (0002) to support these classes. This
should allow work to be done on the public API based off of these models.

In addition, this commit restructures the test package for the web_api
Django app, and adds a modest set of unit tests for the afforementioned
model classes.
Add modified field to EmailThread

The save() methods on Item, NewPostEmail, and ClaimedItemEmail have been
overriden to automatically update the EmailThread.modified field. In terms
of efficiency, this makes more sense than having a property on EmailThread
(implemented by overriding __getatr__) that pulls the values of the
associated Item, NewPostEmail, and ClaimedEmail objects. The reasoning
here is that the field will be read much more often than written, so
making it usable in an SQL query condition is more important than
preventing a little bit of data duplication.
Add web_api.EmailParser class for parsing emails

The EmailParser class is responsible for turning incoming text into a set
of meaningful fields, namely who the email is from, what the subject is,
and what the body is. Since not all messages are pure text, this turns out
to be non-trivial.
Bug fix in test case for NewPostEmail
Fix settings.py to use the correct databases

There was a bug in using "is" instead of "==" to compare hostnames, and
using next() on a list instead of an iterator.
Merge branch 'unstable' of https://github.com/ARmadillo-reuse/api-server
Fix permission error when checking branch

Use the directory name instead of calling out to git to determine whether to
select the stable or unstable database.
set up initial api urls and views
set up basic email verification
implemented post, claim and get
Move EmailParser to web_api.processing package
Add reply and signature removal to EmailParser

Both of these capabilities are pretty basic; they just look for patterns
and use those to remove chunks of messages. Signatures are identified
either by a line of dashes or similar, or, failing that, by a set of
simple heuristics that appear to work fairly well. The test suite was
expanded to include test cases for these specific features.
Rename EmailParser as EmailPreProcessor
Fix bug in EmailPreProcessor

Certain messages were causing infinite recursion, which is bad. The error
was caused by assuming that all paths through
EmailPreProcessor#strip_reply either reduced the amount of text or
returned (one of them didn't).
Add EmailParser, implement parse_email_thread
Add thread detection to EmailParser

It currently uses just the subject, and returns an EmailThread object if
one is found, or None otherwise.
Parse Apple Mail emails correctly

Of course, it makes perfect sense to nest multipart messages inside
multipart messages. No problem. The chosen solution is just to parse the
first multipart part recursively.
changed db
Add web_api.location.ItemPostLocator

With a known list of buildings (copied from
floorplans.mit.edu/cgi-bin-db-any/wdbanyscript.asp?Report=bl&Item=OWNED),
ItemPostLocator returns a dictionary with 'lat' and 'lon' keys for a given
item, or None if it can't locate that item.
Attempt basic email type parsing

Three simple rules:
 1. If an email doesn't have a thread, it's a NewPostEmail
 2. If there is a "[PREP] (room)? [BUILDING#]" phrase, it's a NewPostEmail
 3. Othewise, it's a ClaimedItemEmail

It seems to work most of the time.