[script] escape link in toc #316
This commit is contained in:
parent
cb8976f0f4
commit
55f6512cb7
|
@ -127,7 +127,10 @@ def write_readme(j)
|
|||
output << "\n \nJump to \n \n"
|
||||
|
||||
cats.each do |c|
|
||||
temp = "#{' ' unless c['parent']==nil }- [#{c['title']}](\##{c['id']}) \n"
|
||||
title = c['title']
|
||||
m = title.match /\[.*?\]/
|
||||
title = m[0].sub('[', '').sub(']', '') unless m.nil?
|
||||
temp = "#{' ' unless c['parent']==nil }- [#{title}](\##{c['id']}) \n"
|
||||
output << temp
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in New Issue