mirror of
https://github.com/haml/haml.git
synced 2022-11-09 12:33:31 -05:00
Add encoding settings for html2haml
This commit is contained in:
parent
4d699ad276
commit
30b2167dc3
1 changed files with 8 additions and 0 deletions
|
@ -338,6 +338,14 @@ END
|
|||
@module_opts[:html_style_attributes] = true
|
||||
end
|
||||
|
||||
unless ::Haml::Util.ruby1_8?
|
||||
opts.on('-E ex[:in]', 'Specify the default external and internal character encodings.') do |encoding|
|
||||
external, internal = encoding.split(':')
|
||||
Encoding.default_external = external if external && !external.empty?
|
||||
Encoding.default_internal = internal if internal && !internal.empty?
|
||||
end
|
||||
end
|
||||
|
||||
super
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in a new issue