Merge pull request #263 from jnordberg/master

Use bash for the go script
Update admin UI to latest (no change other than README)
Fixed a locking problem in the change-log cache

It was using the cached log object without acquiring a lock first,
in one place.
Changes feed's "changes" property shouldn't include deleted leaf revs

Reported via email by Mike Lamb
Don't read the db's sequence counter every time around the changes-feed loop

This caused huge numbers of GETs of the "_sync:seq" document, and I
don't think it bought much of any optimization in generating the feed.
Reduce number of channel-log queries done by continuous-mode changes feed

Added a mode to MultiChangesFeed that lets it keep running indefinitely
instead of returning after it finds new entries. This lets it keep its
state around, so it will not have to check the channel logs more often
than it needs to.
Handle channel-log-cache requests for too-low sequence numbers

It's possible to tell that a starting sequence number is below any post
in the channel, and just send back the entire cache. This helps keep
the cache from getting messed up by the way the gateload test code
generates fake sequence IDs that often have sequence numbers lower than
any real entry in a channel.

Also, don't record a cache miss if there isn't really any channel log
document yet; this happens almost every time a new channel starts.
Better handling of obsolete/overwritten entries in channel-logs

An entry for a replaced revision shouldn't be removed entirely from the
channel log; its sequence number might still be requested in a changes
feed's "since" parameter. Instead, just strip the entry of everything
but the sequence number, and then suppress such entries from the API
that returns log entries.
Fixes #268
Fixed regression where duplicate entries appeared in changes feed

Stupid bug where I removed empty entries in place from a shared array,
messing up the original channel-log cache.
Changes feed shouldn't show doc as deleted if it has a live branch
Make db.GetChangeLog checkpoint the changesWriter (fixes unit tests)

There were occasional race-condition failures in TestAllDocs, apparently due to
the channel-log not having been rewritten by the time GetChangeLog was
called.
Fixes #277 (but haven't been able to verify it on my machine)
Don't return doc_count in GET /db: it's too expensive to compute

Fixes #278
Add have* functions to sync function scope