From d41e9d72aab2623212df76821b05c483858281a6 Mon Sep 17 00:00:00 2001 From: mgcaret Date: Mon, 20 Jan 2020 23:09:09 -0800 Subject: [PATCH] add some escapes so markdown renders better --- utils/index2md.rb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/utils/index2md.rb b/utils/index2md.rb index f29edc1..10b7c21 100755 --- a/utils/index2md.rb +++ b/utils/index2md.rb @@ -33,7 +33,9 @@ puts index.keys.sort.each do |word| word_info = index[word] - puts "## #{word}" + cword = word.gsub(/^(#+)$/) { "\\#{$1}" } # let '#' display properly + cword.gsub!(/^([<>])/) { "\\#{$1}" } + puts "## #{cword}" puts if word_info['help'] word_info['help'].each_with_index do |line, i|