Afra

FIXME:
* For some reason the user is redirected to /_-_ after authentication.
* Logout.

TODO:
* Check if Omniauth works without proxy.
* MIT License.
* Testing:
  * Backend:
    * Spec User model.
    * Spec Web  class.
    * rake test:spec - run all specs
    * rake - run all tests (alias to test:spec for now)
  * Frontend:
    * ...
* Build:
  * Frontend:
    * asset compilation, processing, & minification
    * grunt?
  * Backend:
    * ...

* Login:
  * Google+ & Twitter login
  * Login button should authenticate through a provider in a popup.

INVESTIGATE:
* bower / volo / jspm.io to manage RJS shims.
* Pack API calls into a separate class?
  * Like Rack::Static?
  * Move methods from Web::SessionManager to Web?
* Angular:
  * nav should be a directive
  * resolve.user should be a service
* Sequel:
  * Rewrite User & SessionToken models using Sequel
  * Keep database.rb? Probably not.
* Organize backend code Rails style? Angular style?

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

Included JBrowse as git submodule, tracked from gh/yeban/jbrowse/afra.

Included for testing:
* MAKER2 generated gene prediction in GFF3 format for two scaffolds of fire ant
  genome.
* Gene prediction for the two scaffolds of fire ant genome in JB/JSON format.

If you `rackup -I lib`, then visit localhost:9292/#/genome, you will see a
working instance of JBrowse with a navbar on top.

NOTES

  * JB and supporting Dojo libraries have been symlinked from jbrowse/src into
    app/src/vendor.
  * All CSS dependencies of JBrowse have been compiled into one jbrowse.css
    file, with modifications to import directives to load necessary CSS from
    app/src/vendor.
  * All images from jbrowse/img have been copied to app/img.
  * JB's data is served from app/data/jb.

TODO
* Move to bower for JB.
* Introduce Task model.
  * Script to populate tasks table from data/ev.
* /genome
  * Get the location of a task's JSON from server and call new Viewer() with
    it.  new Viewer() will require and initialize JB.
  * Add Next button at the bottom.  Clicking Next moves to next genomic
    location of interest.
  * JB shouldn't set page title.
  * Remove 'Full View' link.
  * Improve styling of tracks.
  * If possible, use fonts-awesome instead of JB's icon set.
* Rewrite JB's Perl scripts in Ruby.
  * contents of data/jb should not be a part of the repository
* Include a BAM file (and data in all formats supported by JB?) for
  testing.
* Similarly, make JB/WA work.

When this commit is finalized, you should be able to:
* Visit /genome after login.
* Browse genome.
* Edit annotations.
* Next button takes you the next interesting genomic locus.

* Backend: save a submission, associate task & submission with user.

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