Boilerplate.

TODO

* MIT License.
* If a user tries to visit /#/genome before authenticating herself, she is
  redirected to /#/login.  After successful authentication, she must be
  redirected to /#/genome.  However, at the moment, a user is invariably
  redirected to /#/ afer authentication.
* Login
  * Google+ & Twitter login.
  * Login button should authenticate through a provider in a popup.

-----
* Build infrastructure for app/.
  Consider using rake vs grunt.
  * rake (grunt) compile index.html to use version number from bower.json in
    urlArgs.
  * supports asset compilation and minification

* Testing
  * Backend
    * Spec User model.
    * Spec Web  class.
    * rake spec is a stub at the moment. Make it run specs for real once we have
      some.
  * Frontend
    * Use Mocha.
      Never done frontend testing. This might take time.
  * Test reverse proxy, sub-uri deployments.

* Pack API calls into a separate class?
  * Like Rack::Static?
  * Move methods from Web::SessionManager to Web?
* Sequel:
  * Rewrite User & SessionToken models using Sequel
  * Keep database.rb? Probably not.

* Trim base.less? Add all BS components?
* BS responsive design from start?

Signed-off-by: Anurag Priyam <anurag08priyam@gmail.com>
Annotation editor.

Launch the server and direct the browser to `/#/curate`.  Login, if need be,
and you will see the first curation task.  Hit `Done` to save the curated gene
model on the server and move to the next task.

Annotation editing functionality builds on the excellent work done by JBrowse
and WebApollo.

JBrowse / WebApollo integration
-------------------------------

JB and WA code, with several modifications, lives as a part of the source tree
in app/src/JBrowse and JBrowse/WebApollo.

JB contains upstream’s src/JBrowse, img, and all CSS (including that of WA --
just one line) compiled into one styles.css.  JB/WA contains upstream’s WA/js.
I hacked JB’s plugin system so that loading CSS for plugins is none of it’s
concern, additionally removing the dependency on lazyload.  JB/main.js loads
styles.css using require-css and WA using the reduced plugin architecture. This
combines JB & WA into one unit.

JB/main.js instantiates JB and returns a facade object.  Rest of Afra
inter-operates with JB through the facade.  At the moment we have a single API
call, `load`, to load a task into JB.  We will need another API call to access
contents of the annotations track.

JB’s dependencies are managed through Bower. I have locked to the latest
point-release of the dependencies that follow semantic versioning.  While we
track rolling updates from Github for the rest -- either Bower doesn’t support
locking to a SHA or it just didn’t work on my Mac.  It’s worth noting that
these dependencies are extremely focussed and move slow: hopefully things won’t
break for a while.  In the near future, we should be able to remove a few more
dependencies and / or lock to a working SHA using Bower.  WA depends on some
old release of jqueryui and I have made it a part of the source tree
(app/src/jqueryui) to get thing rolling for now.

I modified default track styles for JB so it looks quite presentable.  I intend
to trim styles.css to bare minimum and maybe convert it to LESS as and when I
get time.  Much of what we carry in JB/img and the bulk of JB’s desktop-UI
components can be safely removed.  This would be further compiled, minified,
sprite-ified, etc by the build system.

Perl sub-system of JB & WA is a part of the source tree as well: Perl modules
in src/perl5 and executable scripts in bin.  setup.sh lives as a part of `rake
setup` and installs dependencies to $HOME/.extlib.  Additionally, I dropped
support for the deprecated legacy wiggle format and legacy bam-to-json.pl.

Included for testing, MAKER2 generated gene prediction in GFF3 format for two
scaffolds of fire ant genome.

FIXME

* Unable to zoom out

TODO

* Make editing work
* Include a BAM file (and data in all formats supported by JB?) for
  testing.

Signed-off-by: Anurag Priyam <anurag08priyam@gmail.com>
Mock dashboard.

Signed-off-by: Anurag Priyam <anurag08priyam@gmail.com>
Drag n drop an evidence track to edit track.

Signed-off-by: Anurag Priyam <anurag08priyam@gmail.com>
drag boundaries to edit

You can drag feature boundaries, but it doesn't persist.

Signed-off-by: Anurag Priyam <anurag08priyam@gmail.com>