1
0
Fork 0
mirror of https://github.com/haml/haml.git synced 2022-11-09 12:33:31 -05:00

[Haml] Make html2haml fully respect --trace.

This commit is contained in:
Nathan Weizenbaum 2009-09-21 12:34:39 -07:00
parent 50e5e52ea9
commit faf2518f98
2 changed files with 7 additions and 1 deletions

View file

@ -3,6 +3,11 @@
* Table of contents
{:toc}
## 2.2.6 (Unreleased)
* Made the error message when unable to load a dependency for html2haml
respect the `--trace` option.
## [2.2.5](http://github.com/nex3/haml/commit/2.2.5)
* Got rid of trailing whitespace produced when opening a conditional comment

View file

@ -364,7 +364,8 @@ END
require 'haml/html'
rescue LoadError => err
dep = err.message.scan(/^no such file to load -- (.*)/)[0]
puts "Required dependency #{dep} not found!"
raise err if @options[:trace] || dep.nil? || dep.empty?
$stderr.puts "Required dependency #{dep} not found!\n Use --trace for backtrace."
exit 1
end
end