Created
August 4, 2011 22:39
-
-
Save JakubOboza/1126472 to your computer and use it in GitHub Desktop.
backend
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'sinatra' | |
set :public, File.dirname(__FILE__) + '/public' | |
get '/' do | |
%q{ | |
<head> | |
<link rel=stylesheet href="/main.css" type="text/css" media=screen> | |
<meta name="viewport" content="initial-scale=1.0, user-scalable=no" /> | |
<script type="text/javascript" | |
src="http://maps.google.com/maps/api/js?sensor=true"> | |
</script> | |
<script type="text/javascript" src="/jquery.js"></script> | |
<script type="text/javascript" src="/application.js"></script> | |
<script type="text/javascript" src="/map.js"></script> | |
<script type="text/javascript" src="/faye.js"></script> | |
</head> | |
<body> | |
<div id="map"></div> | |
</body> | |
} | |
end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require "rubygems" | |
require "bundler/setup" | |
require 'faye' | |
require File.dirname(__FILE__) + '/app' | |
use Faye::RackAdapter, :mount => '/faye', | |
:timeout => 25 | |
run Sinatra::Application |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment