sass 3.1.0.alpha.44 → 3.1.0.alpha.45

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1 +1 @@
1
- 3.1.0.alpha.44
1
+ 3.1.0.alpha.45
data/VERSION CHANGED
@@ -1 +1 @@
1
- 3.1.0.alpha.44
1
+ 3.1.0.alpha.45
@@ -231,6 +231,9 @@ END
231
231
  opts.on('-q', '--quiet', 'Silence warnings and status messages during compilation.') do
232
232
  @options[:for_engine][:quiet] = true
233
233
  end
234
+ opts.on('--compass', 'Loads compass.') do
235
+ @options[:compass] = true
236
+ end
234
237
  opts.on('-g', '--debug-info',
235
238
  'Emit extra information in the generated CSS that can be used by the FireSass Firebug plugin.') do
236
239
  @options[:for_engine][:debug_info] = true
@@ -276,7 +279,7 @@ END
276
279
  @options[:update] = true
277
280
  end
278
281
  end
279
-
282
+ load_compass if @options[:compass]
280
283
  return interactive if @options[:interactive]
281
284
  return watch_or_update if @options[:watch] || @options[:update]
282
285
  super
@@ -309,6 +312,22 @@ END
309
312
 
310
313
  private
311
314
 
315
+ def load_compass
316
+ begin
317
+ require 'compass'
318
+ rescue LoadError
319
+ require 'rubygems'
320
+ begin
321
+ require 'compass'
322
+ rescue LoadError
323
+ puts "ERROR: Cannot load compass."
324
+ exit 1
325
+ end
326
+ end
327
+ Compass.add_project_configuration
328
+ @options[:for_engine][:load_paths] += Compass.configuration.sass_load_paths
329
+ end
330
+
312
331
  def interactive
313
332
  require 'sass/repl'
314
333
  ::Sass::Repl.new(@options).run
@@ -1092,7 +1092,6 @@ module Sass::Script
1092
1092
  # @param if_true [Literal] The value that will be returned if `$condition` is true.
1093
1093
  # @param if_false [Literal] The value that will be returned if `$condition` is false.
1094
1094
  def if(condition, if_true, if_false)
1095
- assert_type condition, :Bool
1096
1095
  if condition.to_bool
1097
1096
  if_true
1098
1097
  else
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sass
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.1.0.alpha.44
4
+ version: 3.1.0.alpha.45
5
5
  platform: ruby
6
6
  authors:
7
7
  - Nathan Weizenbaum