lib/deface/dsl/loader.rb in deface-1.0.0.rc1 vs lib/deface/dsl/loader.rb in deface-1.0.0.rc2

- old
+ new

@@ -60,10 +60,11 @@ unless first_close_comment_index.nil? comment = html_file_contents[first_open_comment_index..first_close_comment_index+2] end comment.gsub('<!--', '').gsub('-->', '').strip.scan(/[^\s"']+|"[^"]*"|'[^']*'/).each do |part| - dsl_commands =~ /('|")\z/ || part =~ /\w\z/ ? dsl_commands << "\n" : dsl_commands << ' ' + + dsl_commands =~ /('|")\z/ || part =~ /\A[^\d:='"%]/ ? dsl_commands << "\n" : dsl_commands << ' ' dsl_commands << part end html_file_contents = html_file_contents.gsub(comment, '') end