This file contains 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
Let's make a list of Sinatra-based apps! | |
Apps: | |
- http://github.com/cschneid/irclogger "Sinatra based irclogger.com" | |
- http://github.com/rtomayko/wink "minimalist blogging engine" | |
- http://github.com/foca/integrity "The easy and fun Continuous Integration server" | |
- http://github.com/sr/git-wiki "git-powered wiki" | |
- http://github.com/entp/seinfeld "Seinfeld-inspired productivity calendar to track your public github commits." | |
- http://github.com/karmi/marley "Marley, the blog engine without <textareas>." | |
- http://github.com/ichverstehe/gaze "Serve up your Markdown files with this tiny Sinatra app!" |
This file contains 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
get '/' do | |
haml :index | |
end | |
post '/unwind' do | |
@url, @unwound_url, @unwind_error = unwind(params[:url]) | |
haml :index | |
end | |
This file contains 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
get '/' do | |
haml :index | |
end | |
post '/unwind' do | |
@url, @unwound_url, @unwind_error = unwind(params[:url]) | |
haml :index | |
end | |
This file contains 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
get '/' do | |
haml :index | |
end | |
post '/unwind' do | |
@url, @unwound_url, @unwind_error = unwind(params[:url]) | |
haml :index | |
end | |
get '/unwind.json' do |
This file contains 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
def test_index | |
get_it '/' | |
assert_match /Unwind It/, @response.body | |
end | |
def test_unwind_with_blank_url | |
post_it '/unwind', :url => '' | |
assert_match /Please enter/, @response.body | |
end |
This file contains 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 'vendor/sinatra/lib/sinatra.rb' | |
disable :run | |
set :env, :production | |
set :raise_errors, true | |
set :views, File.dirname(__FILE__) + '/views' | |
set :public, File.dirname(__FILE__) + '/public' | |
set :app_file, __FILE__ | |
This file contains 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 'sinatra' | |
disable :run | |
require 'urlunwind.rb' | |
run Sinatra.application |
This file contains 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 'sinatra' | |
disable :run | |
set :views, File.dirname(__FILE__) + '/views' | |
set :public, File.dirname(__FILE__) + '/public' | |
set :app_file, __FILE__ | |
require 'urlunwind.rb' | |
run Sinatra.application |
This file contains 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 'sinatra' | |
disable :run | |
set :env, :production | |
set :raise_errors, true | |
set :views, File.dirname(__FILE__) + '/views' | |
set :public, File.dirname(__FILE__) + '/public' | |
set :app_file, __FILE__ | |
This file contains 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
#-*-ruby-*- | |
load 'deploy' if respond_to?(:namespace) # cap2 differentiator | |
default_run_options[:pty] = true | |
# be sure to change these | |
set :user, 'app_user' | |
set :domain, 'urlunwind.com' | |
set :application, 'url_unwind' | |
set :git_path_prefix, "[email protected]/tobias/" |
OlderNewer