get rid of useless latex parsing code
This commit is contained in:
parent
c383893e77
commit
133e035510
1 changed files with 0 additions and 28 deletions
|
@ -1,33 +1,5 @@
|
|||
require "mathematical"
|
||||
|
||||
# module Jekyll
|
||||
# class LatexGenerator < Generator
|
||||
# safe true
|
||||
# def generate(site)
|
||||
# blockRgx = /\$\$[^\$]+\$\$/
|
||||
# site.posts.each do |post|
|
||||
# buf = StringIO.new
|
||||
# prev = 0
|
||||
# post.content.to_enum(:match, blockRgx).with_index.each do |match, i|
|
||||
# a, b = match.offset(i)
|
||||
# buf << post.content[prev..a]
|
||||
|
||||
# render = Mathematical.new.render(match[i])
|
||||
# buf << render[:data]
|
||||
|
||||
# prev = b
|
||||
# end
|
||||
# buf << post.content[prev..post.content.length]
|
||||
# p buf.string
|
||||
# end
|
||||
# inlineRgx = /[^\$]\$[^\$]+\$[^\$]/
|
||||
# site.posts.each do |post|
|
||||
# p post.content.scan(inlineRgx)
|
||||
# end
|
||||
# end
|
||||
# end
|
||||
# end
|
||||
|
||||
$blockRgx = /((?<block>\$\$[^\$]+\$\$)|[^\$](?<inline>\$[^\$]+\$)[^\$])/
|
||||
|
||||
module Jekyll
|
||||
|
|
Loading…
Reference in a new issue