Permalink
Browse files

Yield config so additional, custom recipes can be added

Add trivial sinatra example
  • Loading branch information...
Bruce Williams
Bruce Williams committed Jan 31, 2009
1 parent 7148cbe commit 5284559d54432b51c357bac5a2bfe391d2aa9c7e
Showing with 12 additions and 0 deletions.
  1. +11 −0 examples/simple.rb
  2. +1 −0 lib/fiveruns/dash/sinatra.rb
View
@@ -0,0 +1,11 @@
+require 'rubygems'
+require 'sinatra'
+require 'fiveruns/dash/sinatra'
+
+configure :production do
+ Fiveruns::Dash::Sinatra.start('APP-TOKEN-HERE')
+end
+
+get '/' do
+ "A simple example."
+end
@@ -17,6 +17,7 @@ def self.start(token)
Fiveruns::Dash.start(:app => token) do |config|
config.add_recipe :sinatra
config.add_recipe :ruby
+ yield config if block_given?
end
end

0 comments on commit 5284559

Please sign in to comment.