compass 1.0.0.alpha.21 → 1.0.0.rc.0

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.
Files changed (53) hide show
  1. checksums.yaml +4 -4
  2. data/Rakefile +11 -5
  3. data/features/command_line.feature +5 -25
  4. data/features/step_definitions/command_line_steps.rb +3 -3
  5. data/lib/compass.rb +2 -2
  6. data/lib/compass/actions.rb +4 -3
  7. data/lib/compass/commands/update_project.rb +50 -45
  8. data/lib/compass/commands/watch_project.rb +62 -13
  9. data/lib/compass/compiler.rb +2 -0
  10. data/lib/compass/configuration/adapters.rb +21 -0
  11. data/lib/compass/configuration/helpers.rb +8 -0
  12. data/lib/compass/deprecation.rb +19 -0
  13. data/lib/compass/exec/global_options_parser.rb +0 -4
  14. data/lib/compass/generated_version.rb +4 -0
  15. data/lib/compass/logger.rb +31 -18
  16. data/lib/compass/sass_compiler.rb +134 -0
  17. data/lib/compass/sass_extensions/functions/sprites.rb +3 -3
  18. data/lib/compass/sprite_importer.rb +1 -1
  19. data/lib/compass/version.rb +29 -31
  20. data/test/fixtures/stylesheets/compass/css/background-clip.css +2 -0
  21. data/test/fixtures/stylesheets/compass/css/background-origin.css +2 -0
  22. data/test/fixtures/stylesheets/compass/css/background-size.css +3 -0
  23. data/test/fixtures/stylesheets/compass/css/browser-support.css +22 -11
  24. data/test/fixtures/stylesheets/compass/css/filters.css +6 -6
  25. data/test/fixtures/stylesheets/compass/css/grid_background.css +4 -0
  26. data/test/fixtures/stylesheets/compass/css/support.css +6 -6
  27. data/test/fixtures/stylesheets/compass/css/transition.css +19 -0
  28. data/test/fixtures/stylesheets/compass/css/vertical_rhythm_with_ems.css +1 -0
  29. data/test/fixtures/stylesheets/compass/css/vertical_rhythm_with_px.css +1 -0
  30. data/test/fixtures/stylesheets/compass/css/vertical_rhythm_with_rems.css +1 -0
  31. data/test/fixtures/stylesheets/sourcemaps/css/another_simple.css +1 -0
  32. data/test/fixtures/stylesheets/sourcemaps/css/another_simple.css.map +2 -1
  33. data/test/fixtures/stylesheets/sourcemaps/css/simple.css +1 -0
  34. data/test/fixtures/stylesheets/sourcemaps/css/simple.css.map +2 -1
  35. data/test/fixtures/stylesheets/sourcemaps/css/with_libraries.css +1 -0
  36. data/test/fixtures/stylesheets/sourcemaps/css/with_libraries.css.map +2 -1
  37. data/test/integrations/compass_test.rb +5 -4
  38. data/test/units/caniuse_test.rb +8 -2
  39. data/test/units/command_line_test.rb +3 -3
  40. data/test/units/compiler_test.rb +7 -2
  41. data/test/units/configuration_test.rb +1 -1
  42. metadata +9 -22
  43. data/RELEASE_VERSION +0 -1
  44. data/VERSION +0 -1
  45. data/lib/compass/watcher.rb +0 -11
  46. data/lib/compass/watcher/compiler.rb +0 -60
  47. data/lib/compass/watcher/project_watcher.rb +0 -179
  48. data/lib/compass/watcher/watch.rb +0 -51
  49. data/test/fixtures/stylesheets/valid/css/another_simple.css +0 -4
  50. data/test/fixtures/stylesheets/valid/css/simple.css +0 -4
  51. data/test/units/watcher/compiler_test.rb +0 -39
  52. data/test/units/watcher/project_watcher_test.rb +0 -85
  53. data/test/units/watcher/watch_test.rb +0 -42
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 98142ce60fa2216da11a92493a53638d0b27305d
4
- data.tar.gz: 03fed89e7920ea0f968dd5978a63f3e8acd964e7
3
+ metadata.gz: a26745c6095de368da35711b64f29a0be0a3897e
4
+ data.tar.gz: a00c977cd66bd80da2dd604bb4f52aecb989636f
5
5
  SHA512:
6
- metadata.gz: 34becf7dc33fdb3afecee8001cf8c649683ddf19ee8d52ed6b74d4d08b08563867c7303ddc4687a1d84876182dea575591d752f71fa270d380e7635584b8b6ca
7
- data.tar.gz: 73652bdf46ad7586d75fb1ad1f58d7390ced875b32e0d6bff60cf14360d61e7ed355dd6a24a185488d79dc3cbed30da264fbd7a20e4eeea7a4812be510b7bdb2
6
+ metadata.gz: 50187461fe4d727c49786feb10cba2666191d842c42caa81242c40017fe3549128a24ff1750a93f2c8110912937e9bb7d865676881d628af9f57df987619e9a8
7
+ data.tar.gz: bf6637915bb3f293cbfd702bf04f43a994010941fad637bc0a3e9cb965b3c5634ca56cbe99ba198c9cbebf4a4d7aff95459e2f5e185b1819417f374cc598c82f
data/Rakefile CHANGED
@@ -1,4 +1,4 @@
1
- FileUtils.rm_f(FileList["RELEASE_VERSION"].first)
1
+ sh "git checkout lib/compass/generated_version.rb"
2
2
  require 'rubygems'
3
3
  require 'rubygems/package_task'
4
4
  require 'rake/testtask'
@@ -171,7 +171,8 @@ end
171
171
  # Release tasks
172
172
  gemspec_file = FileList['compass.gemspec'].first
173
173
  spec = eval(File.read(gemspec_file), binding, gemspec_file)
174
- spec.files << "RELEASE_VERSION"
174
+ spec.files.delete("VERSION")
175
+ spec.files.delete("VERSION_NAME")
175
176
 
176
177
  def spec.bump!
177
178
  segments = version.to_s.split(".")
@@ -190,8 +191,13 @@ task :build => [:default, :gem]
190
191
  task :gem => :release_version
191
192
 
192
193
  task :release_version do
193
- open("RELEASE_VERSION", "w") do |f|
194
- f.write(spec.version.to_s)
194
+ open("lib/compass/generated_version.rb", "w") do |f|
195
+ f.write(<<VERSION_EOF)
196
+ module Compass
197
+ VERSION = "#{spec.version}"
198
+ VERSION_NAME = "#{File.read('VERSION_NAME').strip}"
199
+ end
200
+ VERSION_EOF
195
201
  end
196
202
  end
197
203
 
@@ -213,8 +219,8 @@ task :record_version do
213
219
  f.write(spec.version.to_s)
214
220
  end
215
221
  sh "git add VERSION"
222
+ sh "git checkout lib/compass/generated_version.rb"
216
223
  sh %Q{git commit -m "Bump version to #{spec.version}."}
217
- sh "rm RELEASE_VERSION"
218
224
  end
219
225
  end
220
226
 
@@ -25,17 +25,6 @@ Feature: Command Line
25
25
  And a sass file custom_project/sass/screen.scss is created
26
26
  And a css file custom_project/css/screen.css is created
27
27
 
28
- Scenario: Perform a dry run of creating a project
29
- When I create a project using: compass create my_project --dry-run
30
- Then a directory my_project/ is not created
31
- But a configuration file my_project/config.rb is reported created
32
- And a sass file my_project/sass/screen.scss is reported created
33
- And a sass file my_project/sass/print.scss is reported created
34
- And a sass file my_project/sass/ie.scss is reported created
35
- And I am told how to link to /stylesheets/screen.css for media "screen, projection"
36
- And I am told how to link to /stylesheets/print.css for media "print"
37
- And I am told how to conditionally link "IE" to /stylesheets/ie.css for media "screen, projection"
38
-
39
28
  Scenario: Creating a bare project
40
29
  When I create a project using: compass create bare_project --bare
41
30
  Then a directory bare_project/ is created
@@ -73,15 +62,6 @@ Feature: Command Line
73
62
  Then a directory tmp_valid/tmp/ is created
74
63
  And a css file tmp_valid/tmp/simple.css is created
75
64
 
76
- Scenario: Dry Run of Compiling an existing project.
77
- Given I am using the existing project in test/fixtures/stylesheets/valid
78
- When I run: compass compile --dry-run
79
- Then a directory tmp/ is not created
80
- And a css file tmp/simple.css is not created
81
- And a css file tmp/simple.css is reported created
82
- And a css file tmp/another_simple.css is not created
83
- And a css file tmp/another_simple.css is reported created
84
-
85
65
  Scenario: Recompiling a project with no changes
86
66
  Given I am using the existing project in test/fixtures/stylesheets/valid
87
67
  When I run: compass compile
@@ -91,7 +71,7 @@ Feature: Command Line
91
71
  Given I am using the existing project in test/fixtures/stylesheets/valid
92
72
  And I run: compass compile sass/simple.sass
93
73
  Then a sass file sass/another_simple.scss is not mentioned
94
- And a css file tmp/simple.css is reported created
74
+ And a css file tmp/simple.css is reported written
95
75
  And a css file tmp/simple.css is created
96
76
  And a css file tmp/another_simple.css is not created
97
77
 
@@ -100,7 +80,7 @@ Feature: Command Line
100
80
  When I run: compass compile
101
81
  And I run: compass compile sass/simple.sass --force
102
82
  Then a sass file sass/another_simple.scss is not mentioned
103
- And a css file tmp/simple.css is reported identical
83
+ And a css file tmp/simple.css is reported written
104
84
 
105
85
  Scenario: Basic help
106
86
  When I run: compass help
@@ -130,7 +110,7 @@ Feature: Command Line
130
110
  And I wait 1 second
131
111
  And I touch sass/simple.sass
132
112
  And I run: compass compile
133
- Then a css file tmp/simple.css is reported identical
113
+ Then a css file tmp/simple.css is reported written
134
114
 
135
115
  Scenario: Recompiling a project with changes
136
116
  Given I am using the existing project in test/fixtures/stylesheets/valid
@@ -138,7 +118,7 @@ Feature: Command Line
138
118
  And I wait 1 second
139
119
  And I add some sass to sass/simple.sass
140
120
  And I run: compass compile
141
- And a css file tmp/simple.css is reported overwritten
121
+ And a css file tmp/simple.css is reported written
142
122
 
143
123
  Scenario: Cleaning a project
144
124
  Given I am using the existing project in test/fixtures/stylesheets/valid
@@ -163,7 +143,7 @@ Feature: Command Line
163
143
  And I touch sass/simple.sass
164
144
  And I wait 2 seconds
165
145
  And I shutdown the other process
166
- Then a css file tmp/simple.css is reported identical
146
+ Then a css file tmp/simple.css is reported written
167
147
 
168
148
  Scenario: Generate a compass configuration file
169
149
  Given I should clean up the directory: config
@@ -135,11 +135,11 @@ Then "the following files are removed:" do |table|
135
135
  end
136
136
 
137
137
  Then /an? \w+ file ([^ ]+) is reported removed/ do |filename|
138
- @last_result.should =~ /remove.*#{Regexp.escape(filename)}/
138
+ @last_result.should =~ /delete.*#{Regexp.escape(filename)}/
139
139
  end
140
140
 
141
- Then /an? \w+ file ([^ ]+) is reported created/ do |filename|
142
- @last_result.should =~ /create.*#{Regexp.escape(filename)}/
141
+ Then /an? \w+ file ([^ ]+) is reported written/ do |filename|
142
+ @last_result.should =~ /write.*#{Regexp.escape(filename)}/
143
143
  end
144
144
 
145
145
  Then /a \w+ file ([^ ]+) is (?:reported )?compiled/ do |filename|
@@ -2,6 +2,7 @@ module Compass
2
2
  end
3
3
 
4
4
  %w(core
5
+ deprecation
5
6
  dependencies
6
7
  sass_extensions
7
8
  version
@@ -26,8 +27,7 @@ module Compass
26
27
  extend QuickCache
27
28
  end
28
29
 
29
- %w(watcher
30
- configuration/adapters
30
+ %w(configuration/adapters
31
31
  configuration/comments
32
32
  configuration/helpers
33
33
  configuration/serialization
@@ -29,14 +29,14 @@ module Compass
29
29
  raise Compass::FilesystemConflict.new(msg)
30
30
  else
31
31
  log_action :directory, separate("#{basename(dir)}/"), options
32
- FileUtils.mkdir_p(dir) unless options[:dry_run]
32
+ FileUtils.mkdir_p(dir)
33
33
  end
34
34
  end
35
35
 
36
36
  # Write a file given the file contents as a string
37
37
  def write_file(file_name, contents, options = nil, binary = false)
38
38
  options ||= self.options if self.respond_to?(:options)
39
- skip_write = options[:dry_run]
39
+ skip_write = false
40
40
  contents = process_erb(contents, options[:erb]) if options[:erb]
41
41
  if File.exists?(file_name)
42
42
  existing_contents = IO.read(file_name)
@@ -53,7 +53,7 @@ module Compass
53
53
  log_action :create, basename(file_name), options
54
54
  end
55
55
  if skip_write
56
- FileUtils.touch file_name unless options[:dry_run]
56
+ FileUtils.touch file_name
57
57
  else
58
58
  mode = "w"
59
59
  mode << "b" if binary
@@ -84,6 +84,7 @@ module Compass
84
84
  end
85
85
 
86
86
  def relativize(path)
87
+ path = File.expand_path(path)
87
88
  if path.index(working_path+File::SEPARATOR) == 0
88
89
  path[(working_path+File::SEPARATOR).length..-1]
89
90
  elsif block_given?
@@ -39,69 +39,69 @@ module Compass
39
39
 
40
40
  def initialize(working_path, options)
41
41
  super
42
- assert_project_directory_exists! unless dry_run?
42
+ assert_project_directory_exists!
43
43
  end
44
44
 
45
45
  def perform
46
46
  compiler = new_compiler_instance
47
47
  check_for_sass_files!(compiler)
48
- compiler.clean! if compiler.new_config?
49
- error_count = compiler.run
50
- failed! if error_count > 0
48
+ prepare_project!(compiler)
49
+ compiler.compile!
50
+ if compiler.error_count > 0
51
+ compiler.logger.red do
52
+ compiler.logger.log "Compilation failed in #{compiler.error_count} files."
53
+ end
54
+ failed!
55
+ end
56
+ end
57
+
58
+ def prepare_project!(compiler)
59
+ if options[:project_name]
60
+ Compass.configuration.project_path = File.expand_path(options[:project_name])
61
+ end
62
+
63
+ if config_file = new_config?(compiler)
64
+ compiler.logger.record :modified, relativize(config_file)
65
+ compiler.logger.record :clean, relativize(Compass.configuration.css_path)
66
+ compiler.clean!
67
+ end
68
+ end
69
+
70
+ # Determines if the configuration file is newer than any css file
71
+ def new_config?(compiler)
72
+ config_file = Compass.detect_configuration_file
73
+ return false unless config_file
74
+ config_mtime = File.mtime(config_file)
75
+ compiler.file_list.each do |(_, css_filename, _)|
76
+ return config_file if File.exists?(css_filename) && config_mtime > File.mtime(css_filename)
77
+ end
78
+ nil
51
79
  end
52
80
 
53
81
  def check_for_sass_files!(compiler)
54
- if compiler.sass_files.empty? && !dry_run?
82
+ file_list = compiler.file_list
83
+ if file_list.empty?
55
84
  message = "Compass can't find any Sass files to compile.\nIs your compass configuration correct?.\nIf you're trying to start a new project, you have left off the directory argument.\n"
56
85
  message << "Run \"compass -h\" to get help."
57
86
  raise Compass::Error, message
87
+ elsif missing = file_list.find {|(sass_file, _, _)| !File.exist?(sass_file)}
88
+ raise Compass::Error, "File not found: #{missing[0]}"
58
89
  end
59
90
  end
60
91
 
61
- def dry_run?
62
- options[:dry_run]
92
+ def new_compiler_instance
93
+ Compass::SassCompiler.new(compiler_options)
63
94
  end
64
95
 
65
- def new_compiler_instance(additional_options = {})
66
- @compiler_opts ||= begin
67
- compiler_opts = {:sass => Compass.sass_engine_options}
68
- compiler_opts.merge!(options)
69
- compiler_opts[:sass_files] = explicit_sass_files
70
- compiler_opts[:cache_location] = determine_cache_location
71
- compiler_opts[:sourcemap] = Compass.configuration.sourcemap if compiler_opts[:sourcemap].nil?
72
- if options.include?(:debug_info) && options[:debug_info]
73
- compiler_opts[:sass][:debug_info] = options.delete(:debug_info)
74
- end
75
- compiler_opts
76
- end
77
-
78
- @memory_store ||= Sass::CacheStores::Memory.new
79
- @backing_store ||= compiler_opts[:cache_store]
80
- @backing_store ||= Sass::CacheStores::Filesystem.new(determine_cache_location)
81
- @cache_store ||= Sass::CacheStores::Chain.new(@memory_store, @backing_store)
82
- @memory_store.reset!
83
-
84
- Compass::Compiler.new(
85
- working_path,
86
- Compass.configuration.sass_path,
87
- Compass.configuration.css_path,
88
- @compiler_opts.merge(:cache_store => @cache_store).merge(additional_options)
89
- )
96
+ def compiler_options
97
+ transfer_options(options, {}, :time, :debug_info, :only_sass_files, :force)
90
98
  end
91
99
 
92
- def explicit_sass_files
93
- return unless options[:sass_files]
94
- options[:sass_files].map do |sass_file|
95
- if absolute_path? sass_file
96
- sass_file
97
- else
98
- File.join(Dir.pwd, sass_file)
99
- end
100
+ def transfer_options(from, to, *keys)
101
+ keys.each do |k|
102
+ to[k] = from[k] unless from[k].nil?
100
103
  end
101
- end
102
-
103
- def determine_cache_location
104
- Compass.configuration.cache_path || Sass::Plugin.options[:cache_location] || File.join(working_path, ".sass-cache")
104
+ to
105
105
  end
106
106
 
107
107
  class << self
@@ -133,10 +133,15 @@ module Compass
133
133
  if arguments.size > 0
134
134
  parser.options[:project_name] = arguments.shift if File.directory?(arguments.first)
135
135
  unless arguments.empty?
136
- parser.options[:sass_files] = arguments.dup
136
+ parser.options[:only_sass_files] = absolutize(*arguments)
137
137
  end
138
138
  end
139
139
  end
140
+
141
+ def absolutize(*paths)
142
+ paths.map {|path| File.expand_path(path) }
143
+ end
144
+
140
145
  end
141
146
  end
142
147
  end
@@ -1,9 +1,8 @@
1
+ # encoding: UTF-8
1
2
  require 'fileutils'
2
3
  require 'pathname'
3
- require 'compass/commands/base'
4
4
  require 'compass/commands/update_project'
5
- require 'compass/watcher'
6
- require 'sass/plugin'
5
+ require "compass/sass_compiler"
7
6
 
8
7
  module Compass
9
8
  module Commands
@@ -34,20 +33,70 @@ module Compass
34
33
  attr_accessor :last_update_time, :last_sass_files
35
34
 
36
35
  def perform
37
- # '.' assumes you are in the executing directory. so get the full path to the directory
38
- if options[:project_name] == '.'
39
- Compass.configuration.project_path = Dir.pwd
36
+ compiler = new_compiler_instance
37
+ compiler.logger.time = true if options[:time]
38
+ prepare_project!(compiler)
39
+ compiler.logger.log ">>> #{compiler.logger.color(:green)}Compass is watching for changes.#{compiler.logger.color(:clear)} #{compiler.logger.color(:red)}Press Ctrl-C to Stop.#{compiler.logger.color(:clear)}"
40
+ begin
41
+ compiler.watch!(:additional_watch_paths => additional_watch_paths, &method(:notify_watches))
42
+ happy_styling!(compiler.logger)
43
+ rescue Interrupt
44
+ happy_styling!(compiler.logger)
40
45
  end
41
-
42
- project_watcher = Compass::Watcher::ProjectWatcher.new(Compass.configuration.project_path, Compass.configuration.watches, options, options[:poll])
46
+ end
47
+
48
+ def happy_styling!(logger)
49
+ logger.log "\n#{logger.color(:yellow)}★★★ #{logger.color(:blue)}Happy Styling!#{logger.color(:yellow)} ★★★#{logger.color(:clear)}"
50
+ end
51
+
52
+ def compiler_options
53
+ super.merge(:poll => options[:poll])
54
+ end
55
+
56
+ def additional_watch_paths
57
+ Compass.configuration.watches.map do |watch|
58
+ pathname = Pathname.new(File.join(Compass.configuration.project_path, watch.glob))
59
+ real_path = nil
60
+ pathname.ascend do |p|
61
+ if p.exist?
62
+ real_path = p
63
+ break
64
+ end
65
+ end
66
+ real_path
67
+ end.compact.uniq
68
+ end
69
+
70
+ def notify_watches(modified, added, removed)
71
+ project_path = Compass.configuration.project_path
72
+ files = {:modified => modified,
73
+ :added => added,
74
+ :removed => removed}
75
+
76
+ run_once, run_each = Compass.configuration.watches.partition {|w| w.run_once_per_changeset?}
43
77
 
44
- puts ">>> Compass is watching for changes. Press Ctrl-C to Stop."
45
- $stdout.flush
46
-
47
- project_watcher.compile
48
- project_watcher.watch!
78
+ run_once.each do |watcher|
79
+ if file = files.values.flatten.detect{|f| watcher.match?(f) }
80
+ action = files.keys.detect{|k| files[k].include?(file) }
81
+ watcher.run_callback(project_path, relative_to(file, project_path), action)
82
+ end
83
+ end
49
84
 
85
+ run_each.each do |watcher|
86
+ files.each do |action, list|
87
+ list.each do |file|
88
+ if watcher.match?(file)
89
+ watcher.run_callback(project_path, relative_to(file, project_path), action)
90
+ end
91
+ end
92
+ end
93
+ end
94
+ end
50
95
 
96
+ def relative_to(f, dir)
97
+ Pathname.new(f).relative_path_from(Pathname.new(dir))
98
+ rescue ArgumentError # does not share a common path.
99
+ f
51
100
  end
52
101
 
53
102
  class << self
@@ -8,6 +8,8 @@ module Compass
8
8
  attr_accessor :working_path, :from, :to, :options, :sass_options, :staleness_checker, :importer
9
9
 
10
10
  def initialize(working_path, from, to, options)
11
+ Compass::Deprecation.deprecated!(:compass_compiler_constructor,
12
+ "Compass::Compiler is deprecated. Use Compass::SassCompiler instead.")
11
13
  self.working_path = working_path.to_s
12
14
  self.from, self.to = File.expand_path(from), to
13
15
  self.logger = options.delete(:logger)
@@ -30,12 +30,21 @@ module Compass
30
30
  plugin_opts = {:template_location => locations}
31
31
  plugin_opts[:style] = output_style if output_style
32
32
  plugin_opts[:line_comments] = line_comments
33
+ if sass_3_4?
34
+ plugin_opts[:sourcemap] = sourcemap ? :auto : :none
35
+ else
36
+ plugin_opts[:sourcemap] = sourcemap
37
+ end
33
38
  plugin_opts[:cache] = cache unless cache.nil?
34
39
  plugin_opts[:cache_location] = cache_path unless cache_path.nil?
40
+ plugin_opts[:quiet] = disable_warnings if disable_warnings
41
+ plugin_opts[:compass] = {}
42
+ plugin_opts[:compass][:environment] = environment
35
43
  plugin_opts.merge!(sass_options || {})
36
44
  plugin_opts[:load_paths] ||= []
37
45
  plugin_opts[:load_paths] += load_paths
38
46
  plugin_opts[:load_paths] << Compass::SpriteImporter.new
47
+ plugin_opts[:full_exception] = (environment == :development)
39
48
  plugin_opts
40
49
  end
41
50
 
@@ -58,9 +67,17 @@ module Compass
58
67
  engine_opts = {:load_paths => sass_load_paths}
59
68
  engine_opts[:style] = output_style if output_style
60
69
  engine_opts[:line_comments] = line_comments
70
+ if sass_3_4?
71
+ engine_opts[:sourcemap] = sourcemap ? :auto : :none
72
+ else
73
+ engine_opts[:sourcemap] = sourcemap
74
+ end
61
75
  engine_opts[:cache] = cache
62
76
  engine_opts[:cache_location] = cache_path
63
77
  engine_opts[:quiet] = disable_warnings if disable_warnings
78
+ engine_opts[:compass] = {}
79
+ engine_opts[:compass][:environment] = environment
80
+ engine_opts[:full_exception] = (environment == :development)
64
81
  engine_opts.merge!(sass_options || {})
65
82
  end
66
83
 
@@ -80,6 +97,10 @@ module Compass
80
97
  load_paths << Compass::SpriteImporter.new
81
98
  load_paths
82
99
  end
100
+
101
+ def sass_3_4?
102
+ Sass.version[:major] == 3 && Sass.version[:minor] == 4
103
+ end
83
104
  end
84
105
  class Data
85
106
  include Adapters