This is very old and I have not touched it for a while. You probably do not want to use this.
Sinatra Starter App
What is it
- OmniAuth integration
- SASS and CoffeeScript compilation
- Sane directory structure
- A barebones User model, persisted with DataMapper. Includes a TokenPair model as well, to handle refresh tokens with Google OAuth2
- Some simple style defaults: CSS3 Github-style buttons by Nicolas Gallagher, and the 'Sea Farer' typography theme by Russ Maschmeyer
- Rack-flash-enabled flash messages (was surprised to find that this is not a default in Sinatra)
- Rails style view helpers (content_for, form builder, etc) with the padrino-helpers gem.
What I would like to see added
- Asset compilation & concatenation for production
What I don't like about it
- I'd prefer not to use the name
Controllerfor my separate pieces of the Sinatra app, but I can't think of any better name for it right now.
- Install dependencies:
bundle install. Ensure you have a sqlite library installed that is compatible with DataMapper.
- Replace all occurrences of StarterApp with your app name.
- Start the app with
rake serverand navigate to
- Build your thing. You can use
rake server:auto_reloadto start up Rack with Shotgun. This will automatically reload the app on each HTTP request.
Run the tests
- Ruby: Uses Rspec, so just do
Tested with: Ruby 1.9.3p0