Sha256: 3391f42b491c31fb4efdc93f4269bf43ae8067f8ab704f56a6ade00bf86482dc

Contents?: true

Size: 626 Bytes

Versions: 23

Compression:

Stored size: 626 Bytes

Contents

$:.unshift File.dirname(__FILE__)
require 'rubygems'
require 'sinatra/base'
require 'erb'
require 'json'
require 'rhosync_api'

module RhosyncConsole  
  class << self
    ROOT_DIR = File.dirname(File.expand_path(__FILE__)) unless defined? ROOT_DIR

    def root_path(*args)
      File.join(ROOT_DIR, *args)
    end
  end  

  class Server < Sinatra::Base
    set :views,  RhosyncConsole::root_path("app","views")
    set :public, RhosyncConsole::root_path("app","public")
    set :static, true    
    use Rack::Session::Cookie
  end
end

Dir[File.join(File.dirname(__FILE__),"app/**/*.rb")].each do |file|
  require file
end

Version data entries

23 entries across 23 versions & 1 rubygems

Version Path
rhosync-2.0.8 lib/rhosync/console/server.rb
rhosync-2.0.7 lib/rhosync/console/server.rb
rhosync-2.0.6 lib/rhosync/console/server.rb
rhosync-2.0.5 lib/rhosync/console/server.rb
rhosync-2.0.4 lib/rhosync/console/server.rb
rhosync-2.0.3 lib/rhosync/console/server.rb
rhosync-2.0.2 lib/rhosync/console/server.rb
rhosync-2.0.1 lib/rhosync/console/server.rb
rhosync-2.0.0 lib/rhosync/console/server.rb
rhosync-2.0.0.rc2 lib/rhosync/console/server.rb
rhosync-2.0.0.rc1 lib/rhosync/console/server.rb
rhosync-2.0.0.beta13 lib/rhosync/console/server.rb
rhosync-2.0.0.beta12 lib/rhosync/console/server.rb
rhosync-2.0.0.beta11 lib/rhosync/console/server.rb
rhosync-2.0.0.beta10 lib/rhosync/console/server.rb
rhosync-2.0.0.beta9 lib/rhosync/console/server.rb
rhosync-2.0.0.beta8 lib/rhosync/console/server.rb
rhosync-2.0.0.beta7 lib/rhosync/console/server.rb
rhosync-2.0.0.beta6 lib/rhosync/console/server.rb
rhosync-2.0.0.beta4 lib/rhosync/console/server.rb