From cf6b05efa28d5a2cdeaf6cc3e3fcb71575dad2ac Mon Sep 17 00:00:00 2001 From: ChaYoung You Date: Sat, 12 Jul 2014 01:43:09 +0900 Subject: [PATCH] Escape double quotes of the post title --- Rakefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Rakefile b/Rakefile index 7c15332e8b0..74bf1bd314e 100644 --- a/Rakefile +++ b/Rakefile @@ -111,7 +111,7 @@ task :new_post, :title do |t, args| open(filename, 'w') do |post| post.puts "---" post.puts "layout: post" - post.puts "title: \"#{title.gsub(/&/,'&')}\"" + post.puts "title: \"#{title.gsub(/&/,'&').gsub(/"/, "\\\"")}\"" post.puts "date: #{Time.now.strftime('%Y-%m-%d %H:%M:%S %z')}" post.puts "comments: true" post.puts "categories: "