haml 3.1.8 → 3.2.0.alpha.2

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of haml might be problematic. Click here for more details.

Files changed (148) hide show
  1. data/CONTRIBUTING +1 -1
  2. data/README.md +2 -2
  3. data/REVISION +1 -1
  4. data/Rakefile +16 -41
  5. data/VERSION +1 -1
  6. data/VERSION_NAME +1 -1
  7. data/lib/haml/buffer.rb +1 -5
  8. data/lib/haml/compiler.rb +7 -8
  9. data/lib/haml/exec.rb +1 -1
  10. data/lib/haml/helpers.rb +3 -5
  11. data/lib/haml/helpers/action_view_mods.rb +5 -21
  12. data/lib/haml/parser.rb +1 -1
  13. data/lib/haml/template.rb +1 -3
  14. data/lib/haml/util.rb +1 -1
  15. data/test/haml/engine_test.rb +12 -51
  16. data/test/haml/helper_test.rb +8 -25
  17. data/test/haml/html2haml_test.rb +1 -1
  18. data/test/haml/results/whitespace_handling.xhtml +50 -46
  19. data/test/haml/template_test.rb +2 -28
  20. data/test/haml/templates/partial_layout.haml +1 -4
  21. data/test/linked_rails.rb +4 -4
  22. data/vendor/sass/VERSION +1 -1
  23. data/vendor/sass/doc-src/SASS_CHANGELOG.md +2 -115
  24. data/vendor/sass/doc-src/SASS_REFERENCE.md +4 -12
  25. data/vendor/sass/lib/sass.rb +0 -1
  26. data/vendor/sass/lib/sass/cache_stores/base.rb +1 -3
  27. data/vendor/sass/lib/sass/cache_stores/filesystem.rb +0 -2
  28. data/vendor/sass/lib/sass/css.rb +1 -2
  29. data/vendor/sass/lib/sass/engine.rb +23 -39
  30. data/vendor/sass/lib/sass/environment.rb +0 -11
  31. data/vendor/sass/lib/sass/exec.rb +1 -14
  32. data/vendor/sass/lib/sass/importers/base.rb +1 -2
  33. data/vendor/sass/lib/sass/importers/filesystem.rb +13 -18
  34. data/vendor/sass/lib/sass/less.rb +2 -2
  35. data/vendor/sass/lib/sass/plugin.rb +8 -4
  36. data/vendor/sass/lib/sass/plugin/compiler.rb +17 -42
  37. data/vendor/sass/lib/sass/plugin/configuration.rb +2 -0
  38. data/vendor/sass/lib/sass/railtie.rb +1 -1
  39. data/vendor/sass/lib/sass/script/funcall.rb +1 -14
  40. data/vendor/sass/lib/sass/script/functions.rb +1 -44
  41. data/vendor/sass/lib/sass/script/interpolation.rb +0 -9
  42. data/vendor/sass/lib/sass/script/lexer.rb +1 -6
  43. data/vendor/sass/lib/sass/script/list.rb +0 -7
  44. data/vendor/sass/lib/sass/script/literal.rb +0 -5
  45. data/vendor/sass/lib/sass/script/node.rb +0 -8
  46. data/vendor/sass/lib/sass/script/number.rb +5 -28
  47. data/vendor/sass/lib/sass/script/operation.rb +0 -8
  48. data/vendor/sass/lib/sass/script/parser.rb +5 -12
  49. data/vendor/sass/lib/sass/script/string_interpolation.rb +0 -9
  50. data/vendor/sass/lib/sass/script/unary_operation.rb +0 -7
  51. data/vendor/sass/lib/sass/script/variable.rb +0 -5
  52. data/vendor/sass/lib/sass/scss/parser.rb +38 -78
  53. data/vendor/sass/lib/sass/scss/rx.rb +1 -2
  54. data/vendor/sass/lib/sass/scss/static_parser.rb +2 -2
  55. data/vendor/sass/lib/sass/shared.rb +1 -1
  56. data/vendor/sass/lib/sass/tree/comment_node.rb +11 -24
  57. data/vendor/sass/lib/sass/tree/debug_node.rb +1 -1
  58. data/vendor/sass/lib/sass/tree/each_node.rb +1 -1
  59. data/vendor/sass/lib/sass/tree/extend_node.rb +1 -1
  60. data/vendor/sass/lib/sass/tree/for_node.rb +2 -2
  61. data/vendor/sass/lib/sass/tree/function_node.rb +1 -1
  62. data/vendor/sass/lib/sass/tree/if_node.rb +14 -1
  63. data/vendor/sass/lib/sass/tree/mixin_def_node.rb +1 -1
  64. data/vendor/sass/lib/sass/tree/mixin_node.rb +2 -2
  65. data/vendor/sass/lib/sass/tree/node.rb +5 -2
  66. data/vendor/sass/lib/sass/tree/prop_node.rb +9 -2
  67. data/vendor/sass/lib/sass/tree/return_node.rb +1 -1
  68. data/vendor/sass/lib/sass/tree/rule_node.rb +2 -9
  69. data/vendor/sass/lib/sass/tree/variable_node.rb +1 -1
  70. data/vendor/sass/lib/sass/tree/visitors/check_nesting.rb +18 -17
  71. data/vendor/sass/lib/sass/tree/visitors/convert.rb +5 -10
  72. data/vendor/sass/lib/sass/tree/visitors/perform.rb +19 -50
  73. data/vendor/sass/lib/sass/tree/visitors/to_css.rb +15 -9
  74. data/vendor/sass/lib/sass/tree/warn_node.rb +1 -1
  75. data/vendor/sass/lib/sass/tree/while_node.rb +1 -1
  76. data/vendor/sass/lib/sass/util.rb +6 -58
  77. data/vendor/sass/sass.gemspec +1 -2
  78. data/vendor/sass/test/sass/cache_test.rb +0 -15
  79. data/vendor/sass/test/sass/conversion_test.rb +6 -2
  80. data/vendor/sass/test/sass/css2sass_test.rb +0 -9
  81. data/vendor/sass/test/sass/engine_test.rb +26 -124
  82. data/vendor/sass/test/sass/functions_test.rb +0 -13
  83. data/vendor/sass/test/sass/importer_test.rb +0 -110
  84. data/vendor/sass/test/sass/plugin_test.rb +13 -16
  85. data/vendor/sass/test/sass/script_conversion_test.rb +0 -2
  86. data/vendor/sass/test/sass/script_test.rb +0 -18
  87. data/vendor/sass/test/sass/scss/css_test.rb +1 -7
  88. data/vendor/sass/test/sass/scss/scss_test.rb +13 -37
  89. data/vendor/sass/test/sass/test_helper.rb +1 -1
  90. data/vendor/sass/test/sass/util_test.rb +0 -12
  91. data/vendor/sass/vendor/fssm/LICENSE +1 -1
  92. data/vendor/sass/vendor/fssm/README.markdown +27 -55
  93. data/vendor/sass/vendor/fssm/Rakefile +54 -6
  94. data/vendor/sass/vendor/fssm/VERSION.yml +5 -0
  95. data/vendor/sass/vendor/fssm/example.rb +3 -6
  96. data/vendor/sass/vendor/fssm/fssm.gemspec +70 -17
  97. data/vendor/sass/vendor/fssm/lib/fssm.rb +3 -7
  98. data/vendor/sass/vendor/fssm/lib/fssm/backends/fsevents.rb +1 -1
  99. data/vendor/sass/vendor/fssm/lib/fssm/backends/inotify.rb +2 -2
  100. data/vendor/sass/vendor/fssm/lib/fssm/backends/polling.rb +2 -2
  101. data/vendor/sass/vendor/fssm/lib/fssm/backends/rubycocoa/fsevents.rb +10 -10
  102. data/vendor/sass/vendor/fssm/lib/fssm/monitor.rb +9 -19
  103. data/vendor/sass/vendor/fssm/lib/fssm/path.rb +21 -24
  104. data/vendor/sass/vendor/fssm/lib/fssm/pathname.rb +479 -13
  105. data/vendor/sass/vendor/fssm/lib/fssm/state/directory.rb +11 -29
  106. data/vendor/sass/vendor/fssm/lib/fssm/state/file.rb +1 -1
  107. data/vendor/sass/vendor/fssm/lib/fssm/support.rb +12 -41
  108. data/vendor/sass/vendor/fssm/lib/fssm/tree.rb +6 -6
  109. data/vendor/sass/vendor/fssm/profile/prof-cache.rb +3 -3
  110. data/vendor/sass/vendor/fssm/profile/prof-pathname.rb +7 -7
  111. data/vendor/sass/vendor/fssm/spec/path_spec.rb +15 -36
  112. data/vendor/sass/vendor/fssm/spec/spec_helper.rb +6 -6
  113. metadata +78 -125
  114. data/lib/haml/helpers/rails_323_textarea_fix.rb +0 -41
  115. data/test/gemfiles/Gemfile.rails-2.0.x +0 -8
  116. data/test/gemfiles/Gemfile.rails-2.0.x.lock +0 -38
  117. data/test/gemfiles/Gemfile.rails-2.1.x +0 -8
  118. data/test/gemfiles/Gemfile.rails-2.1.x.lock +0 -38
  119. data/test/gemfiles/Gemfile.rails-2.2.x +0 -8
  120. data/test/gemfiles/Gemfile.rails-2.2.x.lock +0 -38
  121. data/test/gemfiles/Gemfile.rails-2.3.x +0 -8
  122. data/test/gemfiles/Gemfile.rails-2.3.x.lock +0 -40
  123. data/test/gemfiles/Gemfile.rails-3.0.x +0 -8
  124. data/test/gemfiles/Gemfile.rails-3.0.x.lock +0 -85
  125. data/test/gemfiles/Gemfile.rails-3.1.x +0 -8
  126. data/test/gemfiles/Gemfile.rails-3.1.x.lock +0 -97
  127. data/test/gemfiles/Gemfile.rails-3.2.x +0 -8
  128. data/test/gemfiles/Gemfile.rails-3.2.x.lock +0 -95
  129. data/test/gemfiles/Gemfile.rails-xss-2.3.x +0 -9
  130. data/test/gemfiles/Gemfile.rails-xss-2.3.x.lock +0 -42
  131. data/vendor/sass/lib/sass/logger.rb +0 -15
  132. data/vendor/sass/lib/sass/logger/base.rb +0 -32
  133. data/vendor/sass/lib/sass/logger/log_level.rb +0 -49
  134. data/vendor/sass/lib/sass/tree/visitors/deep_copy.rb +0 -87
  135. data/vendor/sass/lib/sass/tree/visitors/set_options.rb +0 -97
  136. data/vendor/sass/test/Gemfile +0 -4
  137. data/vendor/sass/test/Gemfile.lock +0 -19
  138. data/vendor/sass/test/sass/fixtures/test_staleness_check_across_importers.css +0 -1
  139. data/vendor/sass/test/sass/fixtures/test_staleness_check_across_importers.scss +0 -1
  140. data/vendor/sass/test/sass/logger_test.rb +0 -58
  141. data/vendor/sass/test/sass/templates/bork5.sass +0 -3
  142. data/vendor/sass/test/sass/templates/nested_bork5.sass +0 -2
  143. data/vendor/sass/vendor/fssm/Gemfile +0 -3
  144. data/vendor/sass/vendor/fssm/lib/fssm/backends/rbfsevent.rb +0 -42
  145. data/vendor/sass/vendor/fssm/lib/fssm/version.rb +0 -3
  146. data/vendor/sass/vendor/fssm/profile/prof-pathname-rubinius.rb +0 -35
  147. data/vendor/sass/vendor/fssm/spec/count_down_latch.rb +0 -151
  148. data/vendor/sass/vendor/fssm/spec/monitor_spec.rb +0 -202
@@ -2,15 +2,13 @@ module FSSM::State
2
2
  class Directory
3
3
  attr_reader :path
4
4
 
5
- def initialize(path, options={})
6
- @path = path
7
- @options = options
8
- @cache = FSSM::Tree::Cache.new
5
+ def initialize(path)
6
+ @path = path
7
+ @cache = FSSM::Tree::Cache.new
9
8
  end
10
9
 
11
10
  def refresh(base=nil, skip_callbacks=false)
12
- base_path = FSSM::Pathname.for(base || @path.to_pathname).expand_path
13
- previous, current = recache(base_path)
11
+ previous, current = recache(base || @path.to_pathname)
14
12
 
15
13
  unless skip_callbacks
16
14
  deleted(previous, current)
@@ -22,36 +20,31 @@ module FSSM::State
22
20
  private
23
21
 
24
22
  def created(previous, current)
25
- (current.keys - previous.keys).sort.each do |file|
26
- @path.create(file, current[file][1])
27
- end
23
+ (current.keys - previous.keys).each {|created| @path.create(created)}
28
24
  end
29
25
 
30
26
  def deleted(previous, current)
31
- (previous.keys - current.keys).sort.reverse.each do |file|
32
- @path.delete(file, previous[file][1])
33
- end
27
+ (previous.keys - current.keys).each {|deleted| @path.delete(deleted)}
34
28
  end
35
29
 
36
30
  def modified(previous, current)
37
31
  (current.keys & previous.keys).each do |file|
38
- current_data = current[file]
39
- @path.update(file, current_data[1]) if (current_data[0] <=> previous[file][0]) != 0
32
+ @path.update(file) if (current[file] <=> previous[file]) != 0
40
33
  end
41
34
  end
42
35
 
43
36
  def recache(base)
44
- base = FSSM::Pathname.for(base)
45
- previous = cache_entries
37
+ base = FSSM::Pathname.for(base)
38
+ previous = @cache.files
46
39
  snapshot(base)
47
- current = cache_entries
40
+ current = @cache.files
48
41
  [previous, current]
49
42
  end
50
43
 
51
44
  def snapshot(base)
52
45
  base = FSSM::Pathname.for(base)
53
46
  @cache.unset(base)
54
- @path.glob.each { |glob| add_glob(base, glob) }
47
+ @path.glob.each {|glob| add_glob(base, glob)}
55
48
  end
56
49
 
57
50
  def add_glob(base, glob)
@@ -60,16 +53,5 @@ module FSSM::State
60
53
  end
61
54
  end
62
55
 
63
- def cache_entries
64
- entries = tag_entries(@cache.files, :file)
65
- entries.merge! tag_entries(@cache.directories, :directory) if @options[:directories]
66
- entries
67
- end
68
-
69
- def tag_entries(entries, tag)
70
- tagged_entries = {}
71
- entries.each_pair { |fname, mtime| tagged_entries[fname] = [mtime, tag] }
72
- tagged_entries
73
- end
74
56
  end
75
57
  end
@@ -8,7 +8,7 @@ module FSSM::State
8
8
 
9
9
  def refresh(base=nil, skip_callbacks=false)
10
10
  base ||= @path.to_pathname
11
- used_to_exist, @exists = @exists, base.exist?
11
+ used_to_exist, @exists = @exists, base.exists?
12
12
  # this handles bad symlinks without failing. why handle bad symlinks at
13
13
  # all? well, we could still be interested in their creation and deletion.
14
14
  old_mtime, @mtime = @mtime, base.symlink? ? Time.at(0) : base.mtime if @exists
@@ -2,34 +2,15 @@ require 'rbconfig'
2
2
 
3
3
  module FSSM::Support
4
4
  class << self
5
- def usable_backend
6
- choice = case
7
- when mac? && !lion? && !jruby? && carbon_core?
8
- 'FSEvents'
9
- when mac? && rb_fsevent?
10
- 'RBFSEvent'
11
- when linux? && rb_inotify?
12
- 'Inotify'
13
- else
14
- 'Polling'
15
- end
16
-
17
- if (mac? || linux?) && choice == 'Polling'
18
- optimal = case
19
- when mac?
20
- 'rb-fsevent'
21
- when linux?
22
- 'rb-inotify'
23
- end
24
- FSSM.dbg("An optimized backend is available for this platform!")
25
- FSSM.dbg(" gem install #{optimal}")
26
- end
27
-
28
- choice
29
- end
30
-
31
5
  def backend
32
- @@backend ||= usable_backend
6
+ @@backend ||= case
7
+ when mac? && !jruby? && carbon_core?
8
+ 'FSEvents'
9
+ when linux? && rb_inotify?
10
+ 'Inotify'
11
+ else
12
+ 'Polling'
13
+ end
33
14
  end
34
15
 
35
16
  def jruby?
@@ -40,10 +21,6 @@ module FSSM::Support
40
21
  Config::CONFIG['target_os'] =~ /darwin/i
41
22
  end
42
23
 
43
- def lion?
44
- Config::CONFIG['target_os'] =~ /darwin11/i
45
- end
46
-
47
24
  def linux?
48
25
  Config::CONFIG['target_os'] =~ /linux/i
49
26
  end
@@ -54,21 +31,13 @@ module FSSM::Support
54
31
  OSX.require_framework '/System/Library/Frameworks/CoreServices.framework/Frameworks/CarbonCore.framework'
55
32
  true
56
33
  rescue LoadError
57
- false
58
- end
59
- end
60
-
61
- def rb_fsevent?
62
- begin
63
- require 'rb-fsevent'
64
- defined?(FSEvent::VERSION) ? FSEvent::VERSION.to_f >= 0.4 : false
65
- rescue LoadError
34
+ STDERR.puts("Warning: Unable to load CarbonCore. FSEvents will be unavailable.")
66
35
  false
67
36
  end
68
37
  end
69
38
 
70
39
  def rb_inotify?
71
- begin
40
+ found = begin
72
41
  require 'rb-inotify'
73
42
  if defined?(INotify::VERSION)
74
43
  version = INotify::VERSION
@@ -77,6 +46,8 @@ module FSSM::Support
77
46
  rescue LoadError
78
47
  false
79
48
  end
49
+ STDERR.puts("Warning: Unable to load rb-inotify >= 0.5.1. Inotify will be unavailable.") unless found
50
+ found
80
51
  end
81
52
 
82
53
  def use_block(context, block)
@@ -34,8 +34,8 @@ module FSSM::Tree
34
34
  def each(prefix=nil, &block)
35
35
  @children.each do |segment, node|
36
36
  cprefix = prefix ?
37
- FSSM::Pathname.for(prefix).join(segment) :
38
- FSSM::Pathname.for(segment)
37
+ FSSM::Pathname.for(prefix).join(segment) :
38
+ FSSM::Pathname.for(segment)
39
39
  block.call([cprefix, node])
40
40
  node.each(cprefix, &block)
41
41
  end
@@ -54,7 +54,7 @@ module FSSM::Tree
54
54
  end
55
55
 
56
56
  segment = key.pop
57
- node = descendant(key)
57
+ node = descendant(key)
58
58
 
59
59
  return unless node
60
60
 
@@ -84,12 +84,12 @@ module FSSM::Tree
84
84
  end
85
85
 
86
86
  def recurse(key, create=false)
87
- key = key_segments(key)
87
+ key = key_segments(key)
88
88
  node = self
89
89
 
90
90
  until key.empty?
91
91
  segment = key.shift
92
- node = create ? node.child!(segment) : node.child(segment)
92
+ node = create ? node.child!(segment) : node.child(segment)
93
93
  return nil unless node
94
94
  end
95
95
 
@@ -127,7 +127,7 @@ module FSSM::Tree
127
127
  end
128
128
 
129
129
  def from_path(path)
130
- path = FSSM::Pathname.for(path)
130
+ path = FSSM::Pathname.for(path)
131
131
  @ftype = path.ftype
132
132
  # this handles bad symlinks without failing. why handle bad symlinks at
133
133
  # all? well, we could still be interested in their creation and deletion.
@@ -5,7 +5,7 @@ require 'fssm'
5
5
  require 'rubygems'
6
6
  require 'ruby-prof'
7
7
 
8
- $test_path = FSSM::Pathname.new('..').expand_path
8
+ $test_path = FSSM::Pathname.new('..').expand_path
9
9
  $test_files = FSSM::Pathname.glob(File.join($test_path, '**', '*'))
10
10
 
11
11
  RubyProf.start
@@ -33,8 +33,8 @@ cache = FSSM::Tree::Cache.new
33
33
  print "\n\n"
34
34
  end
35
35
 
36
- result = RubyProf.stop
37
- output = File.new('prof.html', 'w+')
36
+ result = RubyProf.stop
37
+ output = File.new('prof.html', 'w+')
38
38
 
39
39
  printer = RubyProf::GraphHtmlPrinter.new(result)
40
40
  printer.print(output, :min_percent => 1)
@@ -6,7 +6,7 @@ require 'pathname'
6
6
  require 'rubygems'
7
7
  require 'ruby-prof'
8
8
 
9
- $test_path = "#{Pathname.new('..').expand_path}"
9
+ $test_path = "#{Pathname.new('..').expand_path}"
10
10
  $iterations = 90000
11
11
 
12
12
  class Pathname
@@ -32,15 +32,15 @@ $iterations.times do |num|
32
32
  puts "FSSM::Pathname iteration #{iteration}"
33
33
 
34
34
  RubyProf.resume
35
- p = FSSM::Pathname.new($test_path)
35
+ p = FSSM::Pathname.new($test_path)
36
36
  segments = p.segments
37
37
  RubyProf.pause
38
38
  end
39
39
 
40
40
  puts "\nFSSM Pathname profile finished\n\n"
41
41
 
42
- result = RubyProf.stop
43
- output = File.new('prof-fssm-pathname.html', 'w+')
42
+ result = RubyProf.stop
43
+ output = File.new('prof-fssm-pathname.html', 'w+')
44
44
 
45
45
  printer = RubyProf::GraphHtmlPrinter.new(result)
46
46
  printer.print(output, :min_percent => 1)
@@ -54,15 +54,15 @@ $iterations.times do |num|
54
54
  puts "::Pathname iteration #{iteration}"
55
55
 
56
56
  RubyProf.resume
57
- p = ::Pathname.new($test_path)
57
+ p = ::Pathname.new($test_path)
58
58
  segments = p.segments
59
59
  RubyProf.pause
60
60
  end
61
61
 
62
62
  puts "\nruby Pathname profile finished\n\n"
63
63
 
64
- result = RubyProf.stop
65
- output = File.new('prof-plain-pathname.html', 'w+')
64
+ result = RubyProf.stop
65
+ output = File.new('prof-plain-pathname.html', 'w+')
66
66
 
67
67
  printer = RubyProf::GraphHtmlPrinter.new(result)
68
68
  printer.print(output, :min_percent => 1)
@@ -1,13 +1,13 @@
1
- require "spec_helper"
1
+ require File.expand_path(File.dirname(__FILE__) + '/spec_helper')
2
2
 
3
3
  describe "The File System State Monitor" do
4
4
  describe "paths" do
5
5
  it "should accept a valid filesystem directory" do
6
- lambda { FSSM::Path.new("#{@watch_root}") }.should_not raise_error
6
+ lambda {FSSM::Path.new("#{@watch_root}")}.should_not raise_error
7
7
  end
8
8
 
9
9
  it "should not accept an invalid filesystem directory" do
10
- lambda { FSSM::Path.new('/does/not/exist/kthxbye') }.should raise_error
10
+ lambda {FSSM::Path.new('/does/not/exist/kthxbye')}.should raise_error
11
11
  end
12
12
 
13
13
  it "should default the path to the current directory" do
@@ -27,42 +27,38 @@ describe "The File System State Monitor" do
27
27
  path.glob.should == ['**/*.yml']
28
28
  end
29
29
 
30
- it "should accept an optional option parameter" do
31
- lambda { FSSM::Path.new('.', '**/*.yml', :foo => :bar) }.should_not raise_error
32
- end
33
-
34
30
  it "should default the glob to ['**/*']" do
35
31
  path = FSSM::Path.new
36
32
  path.glob.should == ['**/*']
37
33
  end
38
34
 
39
35
  it "should accept a callback for update events" do
40
- path = FSSM::Path.new
41
- callback = lambda { |base, relative| return true }
42
- path.update(&callback)
36
+ path = FSSM::Path.new
37
+ callback = lambda {|base, relative| return true}
38
+ path.update(callback)
43
39
  (path.update).should == callback
44
40
  end
45
41
 
46
42
  it "should accept a callback for delete events" do
47
- path = FSSM::Path.new
48
- callback = lambda { |base, relative| return true }
49
- path.delete(&callback)
43
+ path = FSSM::Path.new
44
+ callback = lambda {|base, relative| return true}
45
+ path.delete(callback)
50
46
  (path.delete).should == callback
51
47
  end
52
48
 
53
49
  it "should accept a callback for create events" do
54
- path = FSSM::Path.new
55
- callback = lambda { |base, relative| return true }
56
- path.create(&callback)
50
+ path = FSSM::Path.new
51
+ callback = lambda {|base, relative| return true}
52
+ path.create(callback)
57
53
  (path.create).should == callback
58
54
  end
59
55
 
60
56
  it "should accept a configuration block" do
61
57
  path = FSSM::Path.new "#{@watch_root}" do
62
58
  glob '**/*.yml'
63
- update { |base, relative| 'success' }
64
- delete { |base, relative| 'success' }
65
- create { |base, relative| 'success' }
59
+ update {|base, relative| 'success'}
60
+ delete {|base, relative| 'success'}
61
+ create {|base, relative| 'success'}
66
62
  end
67
63
 
68
64
  "#{path}".should == "#{@watch_root}"
@@ -75,22 +71,5 @@ describe "The File System State Monitor" do
75
71
  path.create.call('', '').should == 'success'
76
72
  end
77
73
 
78
- it "should pass file type to callbacks as the third argument if :directories option is used" do
79
- path = FSSM::Path.new "#{@watch_root}", nil, :directories => true do
80
- glob '**/*.yml'
81
- update { |base, relative, type| [base, relative, type] }
82
- delete { |base, relative, type| [base, relative, type] }
83
- create { |base, relative, type| [base, relative, type] }
84
- end
85
-
86
- "#{path}".should == "#{@watch_root}"
87
- path.glob.should == ['**/*.yml']
88
- path.update.should be_a_kind_of(Proc)
89
- path.delete.should be_a_kind_of(Proc)
90
- path.create.should be_a_kind_of(Proc)
91
- path.update.call('b', 'r', 't').should == ['b', 'r', 't']
92
- path.delete.call('b', 'r', 't').should == ['b', 'r', 't']
93
- path.create.call('b', 'r', 't').should == ['b', 'r', 't']
94
- end
95
74
  end
96
75
  end
@@ -1,14 +1,14 @@
1
1
  $LOAD_PATH.unshift(File.dirname(__FILE__))
2
- $LOAD_PATH.unshift(File.expand_path('../lib', File.dirname(__FILE__)))
2
+ $LOAD_PATH.unshift(File.join(File.dirname(__FILE__), '..', 'lib'))
3
3
 
4
- require 'rubygems'
5
- require 'bundler/setup'
4
+ require 'pathname'
6
5
  require 'fssm'
7
6
 
8
- require 'rspec'
7
+ require 'spec'
8
+ require 'spec/autorun'
9
9
 
10
- RSpec.configure do |config|
10
+ Spec::Runner.configure do |config|
11
11
  config.before :all do
12
- @watch_root = FSSM::Pathname.new(__FILE__).dirname.join('root').expand_path
12
+ @watch_root = Pathname.new(__FILE__).dirname.join('root').expand_path
13
13
  end
14
14
  end
metadata CHANGED
@@ -1,113 +1,79 @@
1
- --- !ruby/object:Gem::Specification
1
+ --- !ruby/object:Gem::Specification
2
2
  name: haml
3
- version: !ruby/object:Gem::Version
4
- prerelease:
5
- version: 3.1.8
3
+ version: !ruby/object:Gem::Version
4
+ version: 3.2.0.alpha.2
6
5
  platform: ruby
7
- authors:
6
+ authors:
8
7
  - Nathan Weizenbaum
9
8
  - Hampton Catlin
10
- - Norman Clarke
11
9
  autorequire:
12
10
  bindir: bin
13
11
  cert_chain: []
14
- date: 2013-02-13 00:00:00.000000000 Z
15
- dependencies:
16
- - !ruby/object:Gem::Dependency
12
+
13
+ date: 2011-04-25 00:00:00 -04:00
14
+ default_executable:
15
+ dependencies:
16
+ - !ruby/object:Gem::Dependency
17
17
  name: yard
18
- requirement: !ruby/object:Gem::Requirement
19
- none: false
20
- requirements:
21
- - - ! '>='
22
- - !ruby/object:Gem::Version
23
- version: 0.5.3
24
- version_requirements: !ruby/object:Gem::Requirement
25
- none: false
26
- requirements:
27
- - - ! '>='
28
- - !ruby/object:Gem::Version
29
- version: 0.5.3
30
- prerelease: false
31
18
  type: :development
32
- - !ruby/object:Gem::Dependency
19
+ version_requirement:
20
+ version_requirements: !ruby/object:Gem::Requirement
21
+ requirements:
22
+ - - ">="
23
+ - !ruby/object:Gem::Version
24
+ version: 0.5.3
25
+ version:
26
+ - !ruby/object:Gem::Dependency
33
27
  name: maruku
34
- requirement: !ruby/object:Gem::Requirement
35
- none: false
36
- requirements:
37
- - - ! '>='
38
- - !ruby/object:Gem::Version
39
- version: 0.5.9
40
- version_requirements: !ruby/object:Gem::Requirement
41
- none: false
42
- requirements:
43
- - - ! '>='
44
- - !ruby/object:Gem::Version
45
- version: 0.5.9
46
- prerelease: false
47
28
  type: :development
48
- description: ! " Haml (HTML Abstraction Markup Language) is a layer on top of
49
- XHTML or XML\n that's designed to express the structure of XHTML or XML documents\n
50
- \ in a non-repetitive, elegant, easy way,\n using indentation rather than
51
- closing tags\n and allowing Ruby to be embedded with ease.\n It was originally
52
- envisioned as a plugin for Ruby on Rails,\n but it can function as a stand-alone
53
- templating engine.\n"
54
- email:
55
- - haml@googlegroups.com
56
- - norman@njclarke.com
57
- executables:
29
+ version_requirement:
30
+ version_requirements: !ruby/object:Gem::Requirement
31
+ requirements:
32
+ - - ">="
33
+ - !ruby/object:Gem::Version
34
+ version: 0.5.9
35
+ version:
36
+ description: " Haml (HTML Abstraction Markup Language) is a layer on top of XHTML or XML\n that's designed to express the structure of XHTML or XML documents\n in a non-repetitive, elegant, easy way,\n using indentation rather than closing tags\n and allowing Ruby to be embedded with ease.\n It was originally envisioned as a plugin for Ruby on Rails,\n but it can function as a stand-alone templating engine.\n"
37
+ email: haml@googlegroups.com
38
+ executables:
58
39
  - haml
59
40
  - html2haml
60
41
  extensions: []
42
+
61
43
  extra_rdoc_files: []
62
- files:
44
+
45
+ files:
63
46
  - rails/init.rb
47
+ - lib/haml.rb
64
48
  - lib/haml/buffer.rb
65
49
  - lib/haml/compiler.rb
66
50
  - lib/haml/engine.rb
67
51
  - lib/haml/error.rb
68
52
  - lib/haml/exec.rb
69
53
  - lib/haml/filters.rb
54
+ - lib/haml/helpers.rb
70
55
  - lib/haml/helpers/action_view_extensions.rb
71
56
  - lib/haml/helpers/action_view_mods.rb
72
- - lib/haml/helpers/rails_323_textarea_fix.rb
73
57
  - lib/haml/helpers/xss_mods.rb
74
- - lib/haml/helpers.rb
75
- - lib/haml/html/erb.rb
76
58
  - lib/haml/html.rb
59
+ - lib/haml/html/erb.rb
77
60
  - lib/haml/parser.rb
78
61
  - lib/haml/railtie.rb
79
62
  - lib/haml/root.rb
80
63
  - lib/haml/shared.rb
64
+ - lib/haml/template.rb
81
65
  - lib/haml/template/options.rb
82
66
  - lib/haml/template/patch.rb
83
67
  - lib/haml/template/plugin.rb
84
- - lib/haml/template.rb
85
68
  - lib/haml/util.rb
86
69
  - lib/haml/version.rb
87
- - lib/haml.rb
70
+ - lib/sass.rb
88
71
  - lib/sass/plugin.rb
89
72
  - lib/sass/rails2_shim.rb
90
73
  - lib/sass/rails3_shim.rb
91
- - lib/sass.rb
92
74
  - bin/haml
93
75
  - bin/html2haml
94
76
  - test/benchmark.rb
95
- - test/gemfiles/Gemfile.rails-2.0.x
96
- - test/gemfiles/Gemfile.rails-2.0.x.lock
97
- - test/gemfiles/Gemfile.rails-2.1.x
98
- - test/gemfiles/Gemfile.rails-2.1.x.lock
99
- - test/gemfiles/Gemfile.rails-2.2.x
100
- - test/gemfiles/Gemfile.rails-2.2.x.lock
101
- - test/gemfiles/Gemfile.rails-2.3.x
102
- - test/gemfiles/Gemfile.rails-2.3.x.lock
103
- - test/gemfiles/Gemfile.rails-3.0.x
104
- - test/gemfiles/Gemfile.rails-3.0.x.lock
105
- - test/gemfiles/Gemfile.rails-3.1.x
106
- - test/gemfiles/Gemfile.rails-3.1.x.lock
107
- - test/gemfiles/Gemfile.rails-3.2.x
108
- - test/gemfiles/Gemfile.rails-3.2.x.lock
109
- - test/gemfiles/Gemfile.rails-xss-2.3.x
110
- - test/gemfiles/Gemfile.rails-xss-2.3.x.lock
111
77
  - test/haml/engine_test.rb
112
78
  - test/haml/erb/_av_partial_1.erb
113
79
  - test/haml/erb/_av_partial_2.erb
@@ -136,8 +102,8 @@ files:
136
102
  - test/haml/results/tag_parsing.xhtml
137
103
  - test/haml/results/very_basic.xhtml
138
104
  - test/haml/results/whitespace_handling.xhtml
139
- - test/haml/spec/lua_haml_spec.lua
140
105
  - test/haml/spec/README.md
106
+ - test/haml/spec/lua_haml_spec.lua
141
107
  - test/haml/spec/ruby_haml_test.rb
142
108
  - test/haml/spec/tests.json
143
109
  - test/haml/spec_test.rb
@@ -177,10 +143,16 @@ files:
177
143
  - test/linked_rails.rb
178
144
  - test/test_helper.rb
179
145
  - extra/update_watch.rb
146
+ - vendor/sass/CONTRIBUTING
147
+ - vendor/sass/MIT-LICENSE
148
+ - vendor/sass/README.md
149
+ - vendor/sass/Rakefile
150
+ - vendor/sass/TODO
151
+ - vendor/sass/VERSION
152
+ - vendor/sass/VERSION_NAME
180
153
  - vendor/sass/bin/sass
181
154
  - vendor/sass/bin/sass-convert
182
155
  - vendor/sass/bin/scss
183
- - vendor/sass/CONTRIBUTING
184
156
  - vendor/sass/doc-src/FAQ.md
185
157
  - vendor/sass/doc-src/INDENTED_SYNTAX.md
186
158
  - vendor/sass/doc-src/SASS_CHANGELOG.md
@@ -189,25 +161,24 @@ files:
189
161
  - vendor/sass/ext/extconf.rb
190
162
  - vendor/sass/extra/update_watch.rb
191
163
  - vendor/sass/init.rb
164
+ - vendor/sass/lib/sass.rb
165
+ - vendor/sass/lib/sass/cache_stores.rb
192
166
  - vendor/sass/lib/sass/cache_stores/base.rb
193
167
  - vendor/sass/lib/sass/cache_stores/chain.rb
194
168
  - vendor/sass/lib/sass/cache_stores/filesystem.rb
195
169
  - vendor/sass/lib/sass/cache_stores/memory.rb
196
170
  - vendor/sass/lib/sass/cache_stores/null.rb
197
- - vendor/sass/lib/sass/cache_stores.rb
198
171
  - vendor/sass/lib/sass/callbacks.rb
199
172
  - vendor/sass/lib/sass/css.rb
200
173
  - vendor/sass/lib/sass/engine.rb
201
174
  - vendor/sass/lib/sass/environment.rb
202
175
  - vendor/sass/lib/sass/error.rb
203
176
  - vendor/sass/lib/sass/exec.rb
177
+ - vendor/sass/lib/sass/importers.rb
204
178
  - vendor/sass/lib/sass/importers/base.rb
205
179
  - vendor/sass/lib/sass/importers/filesystem.rb
206
- - vendor/sass/lib/sass/importers.rb
207
180
  - vendor/sass/lib/sass/less.rb
208
- - vendor/sass/lib/sass/logger/base.rb
209
- - vendor/sass/lib/sass/logger/log_level.rb
210
- - vendor/sass/lib/sass/logger.rb
181
+ - vendor/sass/lib/sass/plugin.rb
211
182
  - vendor/sass/lib/sass/plugin/compiler.rb
212
183
  - vendor/sass/lib/sass/plugin/configuration.rb
213
184
  - vendor/sass/lib/sass/plugin/generic.rb
@@ -215,10 +186,10 @@ files:
215
186
  - vendor/sass/lib/sass/plugin/rack.rb
216
187
  - vendor/sass/lib/sass/plugin/rails.rb
217
188
  - vendor/sass/lib/sass/plugin/staleness_checker.rb
218
- - vendor/sass/lib/sass/plugin.rb
219
189
  - vendor/sass/lib/sass/railtie.rb
220
190
  - vendor/sass/lib/sass/repl.rb
221
191
  - vendor/sass/lib/sass/root.rb
192
+ - vendor/sass/lib/sass/script.rb
222
193
  - vendor/sass/lib/sass/script/bool.rb
223
194
  - vendor/sass/lib/sass/script/color.rb
224
195
  - vendor/sass/lib/sass/script/css_lexer.rb
@@ -237,7 +208,7 @@ files:
237
208
  - vendor/sass/lib/sass/script/string_interpolation.rb
238
209
  - vendor/sass/lib/sass/script/unary_operation.rb
239
210
  - vendor/sass/lib/sass/script/variable.rb
240
- - vendor/sass/lib/sass/script.rb
211
+ - vendor/sass/lib/sass/scss.rb
241
212
  - vendor/sass/lib/sass/scss/css_parser.rb
242
213
  - vendor/sass/lib/sass/scss/parser.rb
243
214
  - vendor/sass/lib/sass/scss/rx.rb
@@ -245,13 +216,12 @@ files:
245
216
  - vendor/sass/lib/sass/scss/script_lexer.rb
246
217
  - vendor/sass/lib/sass/scss/script_parser.rb
247
218
  - vendor/sass/lib/sass/scss/static_parser.rb
248
- - vendor/sass/lib/sass/scss.rb
219
+ - vendor/sass/lib/sass/selector.rb
249
220
  - vendor/sass/lib/sass/selector/abstract_sequence.rb
250
221
  - vendor/sass/lib/sass/selector/comma_sequence.rb
251
222
  - vendor/sass/lib/sass/selector/sequence.rb
252
223
  - vendor/sass/lib/sass/selector/simple.rb
253
224
  - vendor/sass/lib/sass/selector/simple_sequence.rb
254
- - vendor/sass/lib/sass/selector.rb
255
225
  - vendor/sass/lib/sass/shared.rb
256
226
  - vendor/sass/lib/sass/tree/charset_node.rb
257
227
  - vendor/sass/lib/sass/tree/comment_node.rb
@@ -276,23 +246,15 @@ files:
276
246
  - vendor/sass/lib/sass/tree/visitors/check_nesting.rb
277
247
  - vendor/sass/lib/sass/tree/visitors/convert.rb
278
248
  - vendor/sass/lib/sass/tree/visitors/cssize.rb
279
- - vendor/sass/lib/sass/tree/visitors/deep_copy.rb
280
249
  - vendor/sass/lib/sass/tree/visitors/perform.rb
281
- - vendor/sass/lib/sass/tree/visitors/set_options.rb
282
250
  - vendor/sass/lib/sass/tree/visitors/to_css.rb
283
251
  - vendor/sass/lib/sass/tree/warn_node.rb
284
252
  - vendor/sass/lib/sass/tree/while_node.rb
285
- - vendor/sass/lib/sass/util/subset_map.rb
286
253
  - vendor/sass/lib/sass/util.rb
254
+ - vendor/sass/lib/sass/util/subset_map.rb
287
255
  - vendor/sass/lib/sass/version.rb
288
- - vendor/sass/lib/sass.rb
289
- - vendor/sass/MIT-LICENSE
290
256
  - vendor/sass/rails/init.rb
291
- - vendor/sass/Rakefile
292
- - vendor/sass/README.md
293
257
  - vendor/sass/sass.gemspec
294
- - vendor/sass/test/Gemfile
295
- - vendor/sass/test/Gemfile.lock
296
258
  - vendor/sass/test/sass/cache_test.rb
297
259
  - vendor/sass/test/sass/callbacks_test.rb
298
260
  - vendor/sass/test/sass/conversion_test.rb
@@ -300,12 +262,9 @@ files:
300
262
  - vendor/sass/test/sass/data/hsl-rgb.txt
301
263
  - vendor/sass/test/sass/engine_test.rb
302
264
  - vendor/sass/test/sass/extend_test.rb
303
- - vendor/sass/test/sass/fixtures/test_staleness_check_across_importers.css
304
- - vendor/sass/test/sass/fixtures/test_staleness_check_across_importers.scss
305
265
  - vendor/sass/test/sass/functions_test.rb
306
266
  - vendor/sass/test/sass/importer_test.rb
307
267
  - vendor/sass/test/sass/less_conversion_test.rb
308
- - vendor/sass/test/sass/logger_test.rb
309
268
  - vendor/sass/test/sass/mock_importer.rb
310
269
  - vendor/sass/test/sass/more_results/more1.css
311
270
  - vendor/sass/test/sass/more_results/more1_with_line_comments.css
@@ -354,7 +313,6 @@ files:
354
313
  - vendor/sass/test/sass/templates/bork2.sass
355
314
  - vendor/sass/test/sass/templates/bork3.sass
356
315
  - vendor/sass/test/sass/templates/bork4.sass
357
- - vendor/sass/test/sass/templates/bork5.sass
358
316
  - vendor/sass/test/sass/templates/compact.sass
359
317
  - vendor/sass/test/sass/templates/complex.sass
360
318
  - vendor/sass/test/sass/templates/compressed.sass
@@ -375,7 +333,6 @@ files:
375
333
  - vendor/sass/test/sass/templates/nested_bork2.sass
376
334
  - vendor/sass/test/sass/templates/nested_bork3.sass
377
335
  - vendor/sass/test/sass/templates/nested_bork4.sass
378
- - vendor/sass/test/sass/templates/nested_bork5.sass
379
336
  - vendor/sass/test/sass/templates/nested_import.sass
380
337
  - vendor/sass/test/sass/templates/nested_mixin_bork.sass
381
338
  - vendor/sass/test/sass/templates/options.sass
@@ -393,14 +350,16 @@ files:
393
350
  - vendor/sass/test/sass/util/subset_map_test.rb
394
351
  - vendor/sass/test/sass/util_test.rb
395
352
  - vendor/sass/test/test_helper.rb
396
- - vendor/sass/TODO
353
+ - vendor/sass/vendor/fssm/LICENSE
354
+ - vendor/sass/vendor/fssm/README.markdown
355
+ - vendor/sass/vendor/fssm/Rakefile
356
+ - vendor/sass/vendor/fssm/VERSION.yml
397
357
  - vendor/sass/vendor/fssm/example.rb
398
358
  - vendor/sass/vendor/fssm/fssm.gemspec
399
- - vendor/sass/vendor/fssm/Gemfile
359
+ - vendor/sass/vendor/fssm/lib/fssm.rb
400
360
  - vendor/sass/vendor/fssm/lib/fssm/backends/fsevents.rb
401
361
  - vendor/sass/vendor/fssm/lib/fssm/backends/inotify.rb
402
362
  - vendor/sass/vendor/fssm/lib/fssm/backends/polling.rb
403
- - vendor/sass/vendor/fssm/lib/fssm/backends/rbfsevent.rb
404
363
  - vendor/sass/vendor/fssm/lib/fssm/backends/rubycocoa/fsevents.rb
405
364
  - vendor/sass/vendor/fssm/lib/fssm/monitor.rb
406
365
  - vendor/sass/vendor/fssm/lib/fssm/path.rb
@@ -409,19 +368,11 @@ files:
409
368
  - vendor/sass/vendor/fssm/lib/fssm/state/file.rb
410
369
  - vendor/sass/vendor/fssm/lib/fssm/support.rb
411
370
  - vendor/sass/vendor/fssm/lib/fssm/tree.rb
412
- - vendor/sass/vendor/fssm/lib/fssm/version.rb
413
- - vendor/sass/vendor/fssm/lib/fssm.rb
414
- - vendor/sass/vendor/fssm/LICENSE
415
371
  - vendor/sass/vendor/fssm/profile/prof-cache.rb
416
372
  - vendor/sass/vendor/fssm/profile/prof-fssm-pathname.html
417
- - vendor/sass/vendor/fssm/profile/prof-pathname-rubinius.rb
418
373
  - vendor/sass/vendor/fssm/profile/prof-pathname.rb
419
374
  - vendor/sass/vendor/fssm/profile/prof-plain-pathname.html
420
375
  - vendor/sass/vendor/fssm/profile/prof.html
421
- - vendor/sass/vendor/fssm/Rakefile
422
- - vendor/sass/vendor/fssm/README.markdown
423
- - vendor/sass/vendor/fssm/spec/count_down_latch.rb
424
- - vendor/sass/vendor/fssm/spec/monitor_spec.rb
425
376
  - vendor/sass/vendor/fssm/spec/path_spec.rb
426
377
  - vendor/sass/vendor/fssm/spec/root/duck/quack.txt
427
378
  - vendor/sass/vendor/fssm/spec/root/file.css
@@ -429,8 +380,6 @@ files:
429
380
  - vendor/sass/vendor/fssm/spec/root/file.yml
430
381
  - vendor/sass/vendor/fssm/spec/root/moo/cow.txt
431
382
  - vendor/sass/vendor/fssm/spec/spec_helper.rb
432
- - vendor/sass/VERSION
433
- - vendor/sass/VERSION_NAME
434
383
  - vendor/sass/yard/callbacks.rb
435
384
  - vendor/sass/yard/default/fulldoc/html/css/common.sass
436
385
  - vendor/sass/yard/default/layout/html/footer.erb
@@ -438,37 +387,41 @@ files:
438
387
  - Rakefile
439
388
  - init.rb
440
389
  - .yardopts
390
+ - README.md
441
391
  - CONTRIBUTING
442
392
  - MIT-LICENSE
443
- - README.md
444
- - REVISION
445
393
  - VERSION
446
394
  - VERSION_NAME
447
- homepage: http://haml.info/
395
+ - REVISION
396
+ has_rdoc: false
397
+ homepage: http://haml-lang.com/
448
398
  licenses: []
399
+
449
400
  post_install_message:
450
401
  rdoc_options: []
451
- require_paths:
402
+
403
+ require_paths:
452
404
  - lib
453
- required_ruby_version: !ruby/object:Gem::Requirement
454
- none: false
455
- requirements:
456
- - - ! '>='
457
- - !ruby/object:Gem::Version
458
- version: '0'
459
- required_rubygems_version: !ruby/object:Gem::Requirement
460
- none: false
461
- requirements:
462
- - - ! '>='
463
- - !ruby/object:Gem::Version
464
- version: '0'
405
+ required_ruby_version: !ruby/object:Gem::Requirement
406
+ requirements:
407
+ - - ">="
408
+ - !ruby/object:Gem::Version
409
+ version: "0"
410
+ version:
411
+ required_rubygems_version: !ruby/object:Gem::Requirement
412
+ requirements:
413
+ - - ">"
414
+ - !ruby/object:Gem::Version
415
+ version: 1.3.1
416
+ version:
465
417
  requirements: []
418
+
466
419
  rubyforge_project: haml
467
- rubygems_version: 1.8.24
420
+ rubygems_version: 1.3.5
468
421
  signing_key:
469
422
  specification_version: 3
470
423
  summary: An elegant, structured XHTML/XML templating engine.
471
- test_files:
424
+ test_files:
472
425
  - test/haml/engine_test.rb
473
426
  - test/haml/helper_test.rb
474
427
  - test/haml/html2haml_test.rb