diff --git a/lib/pliny/commands/creator.rb b/lib/pliny/commands/creator.rb index d1f112c6..dd971e63 100644 --- a/lib/pliny/commands/creator.rb +++ b/lib/pliny/commands/creator.rb @@ -35,7 +35,7 @@ def parse_erb_files Dir.glob("#{app_dir}/{*,.*}.erb").each do |file| static_file = file.gsub(/\.erb$/, '') - template = ERB.new(File.read(file), 0) + template = ERB.new(File.read(file)) context = OpenStruct.new(app_name: name) content = template.result(context.instance_eval { binding }) diff --git a/lib/pliny/commands/generator/base.rb b/lib/pliny/commands/generator/base.rb index 195aea1f..74937f86 100644 --- a/lib/pliny/commands/generator/base.rb +++ b/lib/pliny/commands/generator/base.rb @@ -41,7 +41,7 @@ def display(msg) def render_template(template_file, vars = {}) template_path = File.dirname(__FILE__) + "/../../templates/#{template_file}" - template = ERB.new(File.read(template_path), 0, '>') + template = ERB.new(File.read(template_path), trim_mode: '>') context = OpenStruct.new(vars) template.result(context.instance_eval { binding }) end