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:
parent
50e5e52ea9
commit
faf2518f98
2 changed files with 7 additions and 1 deletions
|
@ -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
|
||||
|
|
|
@ -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
|
||||
|
|
Loading…
Add table
Reference in a new issue