From 930c686626bec74349a655589632f80485abbe92 Mon Sep 17 00:00:00 2001 From: EuAndreh Date: Sat, 14 Nov 2020 09:23:30 -0300 Subject: Indent code of plaintext generator --- _plugins/generate-pastebin-plaintext-alternate.rb | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to '_plugins') diff --git a/_plugins/generate-pastebin-plaintext-alternate.rb b/_plugins/generate-pastebin-plaintext-alternate.rb index 110a943..5ab059d 100644 --- a/_plugins/generate-pastebin-plaintext-alternate.rb +++ b/_plugins/generate-pastebin-plaintext-alternate.rb @@ -16,14 +16,14 @@ module Jekyll .run # generate the HTML string .scan(CODE_BLOCK) # match all occurrences of regexp .each do |code_block| # iterate on each match - unhighlighted_code = code_block[0] # regexp only defines 1 match (only 1 parens) - .gsub(/(.*?)<\/span>/m, '\1') - content = CGI.unescapeHTML unhighlighted_code - name = "#{document.url}.#{n}.txt" - plain = PageWithoutAFile.new(site, site.source, "", name) - plain.content = content - site.pages << plain - n += 1 + unhighlighted_code = code_block[0] # regexp only defines 1 match (only 1 parens) + .gsub(/(.*?)<\/span>/m, '\1') + content = CGI.unescapeHTML unhighlighted_code + name = "#{document.url}.#{n}.txt" + plain = PageWithoutAFile.new(site, site.source, "", name) + plain.content = content + site.pages << plain + n += 1 end end end -- cgit v1.2.3