Skip to content

Commit

Permalink
Camping::Server serve files from public/
Browse files Browse the repository at this point in the history
  • Loading branch information
judofyr committed Jan 15, 2012
1 parent a146341 commit d2899ec
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion lib/camping/server.rb
Expand Up @@ -143,9 +143,13 @@ def start
super
end
end

def public_dir
File.expand_path('../public', @reloader.file)
end

def app
self
Rack::Cascade.new([Rack::File.new(public_dir), self])
end

def current_app
Expand Down

0 comments on commit d2899ec

Please sign in to comment.