Module: Hyde::Server

Defined in:
lib/hyde/server.rb,
lib/hyde/server.rb,
lib/hyde/server.rb

Defined Under Namespace

Modules: PageHelpers

Class Method Summary collapse

Class Method Details

.optionsObject

Available options:

:last_modified  -- timestamp for all files


79
80
81
# File 'lib/hyde/server.rb', line 79

def self.options
  @options ||= Hash.new 
end

.rack_handlerObject



90
91
92
93
94
95
96
97
98
# File 'lib/hyde/server.rb', line 90

def self.rack_handler
  %w(thin mongrel webrick).each do |svr|
    begin
      return Rack::Handler.get(svr)
    rescue LoadError
    rescue NameError
    end
  end
end

.run!(options = {}) ⇒ Object

:Host, :Port



84
85
86
87
88
# File 'lib/hyde/server.rb', line 84

def self.run!(options={})
  self.options.merge options
  handler = rack_handler  or return false
  handler.run self, options
end