mdless 2.1.20 → 2.1.22

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: f57c3bdcee76bfb347f88b0565c5ecd09c7879cc0ed3159d34c38a8ea1abc6cc
4
- data.tar.gz: f7777ae04cad47bdf0b3a9e80737744264698d734ad6bfc4981cab8aaabfb7dd
3
+ metadata.gz: 33b70464b1d4d0051f19031b63db4631baecec21b7e7681de726f069e30e2215
4
+ data.tar.gz: b6965f472976e370b243b355eb3e8c192ad53097fe676d00d06d987a0c0f33c3
5
5
  SHA512:
6
- metadata.gz: 2595a961ba59068748afc2f29790ae1f10d264dad6bc020d3dea33909f74e46924ea335a7fcfbbf02b465428168311a0c98613906a474a6e8c1ab1bdd8c4b1db
7
- data.tar.gz: e8657acc663939813cf5302cbde4f32d8b4d94b2cbdd1988d1a3a809aa1d7ac1912d305221b392ea3ff18ca94464758d1b8cd6b757ea78a09548a26abdd10ded
6
+ metadata.gz: 83407c14da33b50cfb7dcd6fa4be0a4075d2a46ea0d402c4f4b4fa863fa5b146303805647626a39636a5172f5c3b476931f895801aaf169198d1a62abc85a856
7
+ data.tar.gz: e0f786fb82cd271ece96171ba03d4e70430d72a5606d623c4c54acab191fa15d8abd3ad870bbd21ef69dfa939ee434a5ffe72a718ff501b2e700077ea566a202
data/lib/mdless/string.rb CHANGED
@@ -74,7 +74,7 @@ class ::String
74
74
  line = "#{color('metadata marker')}#{'%' * longest}"
75
75
  else
76
76
  line.sub!(/^(.*?:)[ \t]+(\S)/, '\1 \2')
77
- line = "#{color('metadata color')}#{line}<br>"
77
+ line = "#{color('metadata marker')}%#{color('metadata color')}#{line}#{xc}"
78
78
  end
79
79
 
80
80
  line += "\u00A0" * (longest - line.uncolor.strip.length) if (longest - line.uncolor.strip.length).positive?
@@ -39,7 +39,7 @@ module CLIMarkdown
39
39
  def remove_meta(input)
40
40
  first_line = input.split("\n").first
41
41
  if first_line =~ /(?i-m)^---[ \t]*?$/
42
- input.sub!(/(?im)^---[ \t]*\n([\s\S]*?)\n[-.]{3}[ \t]*\n/, '')
42
+ input.sub!(/(?im)^---[ \t]*\n([\s\S\n]*?)\n[-.]{3}[ \t]*\n/, '')
43
43
  elsif first_line =~ /(?i-m)^[\w ]+:\s+\S+/
44
44
  input.sub!(/(?im)^([\S ]+:[\s\S]*?)+(?=\n\n)/, '')
45
45
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module CLIMarkdown
4
- VERSION = '2.1.20'
4
+ VERSION = '2.1.22'
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: mdless
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.1.20
4
+ version: 2.1.22
5
5
  platform: ruby
6
6
  authors:
7
7
  - Brett Terpstra