Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Adding stylesheets path to Sass.load_paths

Adding the stylesheets path to Sass' load_paths allows non Rails
apps to use the assets bundled with the gem directly, instead of
copying them manually into each projects, and manually updating
them.
  • Loading branch information...
commit b7abce3b105aaae36fd6c3453f54e3308ecb7c90 1 parent 47a78ff
@ysbaddaden ysbaddaden authored
Showing with 6 additions and 4 deletions.
  1. +6 −4 lib/bourbon.rb
View
10 lib/bourbon.rb
@@ -4,6 +4,10 @@
require "bourbon/generator"
+unless defined?(Sass)
+ require 'sass'
+end
+
module Bourbon
if defined?(Rails) && defined?(Rails::Engine)
class Engine < ::Rails::Engine
@@ -17,9 +21,7 @@ class Railtie < ::Rails::Railtie
end
end
end
+ else
+ Sass.load_paths << File.expand_path("../../app/assets/stylesheets", __FILE__)
end
end
-
-unless defined?(Sass)
- require 'sass'
-end

1 comment on commit b7abce3

@hakanensari

@plapier I believe this makes the non-Rails installation directions in the README obsolete.

Please sign in to comment.
Something went wrong with that request. Please try again.