Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

We’re showing branches in this repository, but you can also compare across forks.

base fork: jimmycuadra/penguin
base: 843a009350
...
head fork: jimmycuadra/penguin
compare: 9294dde577
  • 2 commits
  • 2 files changed
  • 0 commit comments
  • 1 contributor
Showing with 12 additions and 5 deletions.
  1. +7 −1 assets/template/deck.rb
  2. +5 −4 lib/penguin/application.rb
8 assets/template/deck.rb
View
@@ -1 +1,7 @@
-# Config file will go here eventually
+# Require and set your preferred template engine
+require "haml"
+set :template_engine, :haml
+
+# Require any CSS and JS preprocessors you want to use
+require "sass"
+require "coffee-script"
9 lib/penguin/application.rb
View
@@ -1,7 +1,4 @@
require "sinatra/base"
-require "haml"
-require "sass"
-require "coffee-script"
module Penguin
class Application < Sinatra::Base
@@ -10,6 +7,10 @@ class Application < Sinatra::Base
set :views, root
set :static, true
+ configure do
+ eval File.read(File.expand_path("deck.rb", root))
+ end
+
use Sprockets do |env|
env.append_path root
env.append_path File.expand_path("../../../assets/css", __FILE__)
@@ -17,7 +18,7 @@ class Application < Sinatra::Base
end
get "/" do
- haml :deck
+ send(settings.template_engine, :deck)
end
end
end

No commit comments for this range

Something went wrong with that request. Please try again.