kramdown-asciidoc 1.0.0 → 2.0.1

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: b9e3b18f4837c8739d81fce5fb674ced60b8c3708a5e5ddfa9895c90d2318fe3
4
- data.tar.gz: d86f257533132bc3a4f2b973e5fd503a9934d83308db75672c8d6947948c902e
3
+ metadata.gz: e2f299ca0d156093eca0b0bf206f13bbedb23604e4f6a237b2b5aa16faa76eb0
4
+ data.tar.gz: 7bc8f03b29ecc1986f25c53858a3f4920b3ff3ba8a1d4b3313cee73c4be0dcaa
5
5
  SHA512:
6
- metadata.gz: b00c3a853eaaacbc611905d7e3cacda53864a074017176b3a3eebe5ee41c59b7ee898298f62e18721c54e0930e71c7e037404c2b681c712b65065f429c5483f1
7
- data.tar.gz: 2fb34cf6bf03a7578a3ee31fe293ae5dd7e911753cf30998132ee9f2872f96c673213ae621a68c5cde1afc15591b3db3feaf34b24938b07b972f1ed549d1a0d7
6
+ metadata.gz: 3d67ddef393d8155a0362ca7c8f0a997cf16f232f1293c13c8cb49ffa08009353224fa9703a25a4f1ab3b3b3dc4b048b56721b15d344695ec025ab3c8223efbe
7
+ data.tar.gz: 3ad990caafd8c8dd4eb0854e1af5095be820b735feff16d28aeac09b98967aabbefc43d6ecae35bda318d8cfdf65a691ea1e34e6b8a060337b17086b4a58e61e
data/CHANGELOG.adoc CHANGED
@@ -5,6 +5,60 @@
5
5
  This document provides a high-level view of the changes to {project-name} by release.
6
6
  For a detailed view of what has changed, refer to the {uri-repo}/commits/master[commit history] on GitHub.
7
7
 
8
+ == 2.0.1 (2022-06-29) - @mojavelinux
9
+
10
+ === Fixed
11
+
12
+ * Fix crash when fenced code block is empty and does not specify a language (#93)
13
+ * Fix crash when input contains `<script>` tag (#98)
14
+ * Fix crash if blockquote ends with nested block (#96)
15
+ * Handle text that maps to an abbreviation (#97)
16
+ * Handle front matter value that is parsed as a date or datetime (#95)
17
+
18
+ === Changed
19
+
20
+ * Add JRuby 9.3 to CI matrix
21
+
22
+ === Details
23
+
24
+ {url-repo}/releases/tag/v2.0.1[git tag] | {url-repo}/compare/v2.0.0\...v2.0.1[full diff]
25
+
26
+ == 2.0.0 (2021-07-11) - @mojavelinux
27
+
28
+ === Added
29
+
30
+ * Add support for converting block LaTeX math to stem block
31
+ * Add support for converting span LaTeX math to inline stem macro
32
+ * Add basic support for footnotes (#74)
33
+
34
+ === Fixed
35
+
36
+ * Use File.read instead of IO.read to suppress magic subprocess behavior
37
+ * Enable compatibility with Ruby 3 by declaring rexml as a runtime dependency (#84)
38
+ * Don't crash when converting list item that only contains spaces (#83)
39
+
40
+ === Changed
41
+
42
+ * Upgrade kramdown to 2.3.x and declare kramdown-parser-gfm as runtime dependency (#85)
43
+ * Don't add source style to listing block when language is specified
44
+ * Switch CI to GitHub Actions
45
+ * Run test suite in CI environment on Windows and macOS
46
+ * Apply style rules to source code
47
+
48
+ === Details
49
+
50
+ {uri-repo}/releases/tag/v2.0.0[git tag] | {uri-repo}/compare/v1.0.1\...v2.0.0[full diff]
51
+
52
+ == 1.0.1 (2018-11-28) - @mojavelinux
53
+
54
+ === Fixed
55
+
56
+ * Fixed bin script on Ruby 2.3 (#70)
57
+
58
+ === Details
59
+
60
+ {uri-repo}/releases/tag/v1.0.1[git tag] | {uri-repo}/compare/v1.0.0\...v1.0.1[full diff]
61
+
8
62
  == 1.0.0 (2018-11-07) - @mojavelinux
9
63
 
10
64
  === Changed
data/Gemfile CHANGED
@@ -1,8 +1,23 @@
1
+ # frozen_string_literal: true
2
+
1
3
  source 'https://rubygems.org'
2
4
 
3
5
  gemspec
4
6
 
7
+ without = (Bundler.settings['WITHOUT'] || '').split ':'
8
+
5
9
  group :docs do
6
- gem 'yard'
7
- gem 'asciidoctor'
8
- end
10
+ gem 'asciidoctor', require: false
11
+ gem 'yard', require: false
12
+ end unless without.include? 'docs'
13
+
14
+ group :lint do
15
+ gem 'rubocop', '~> 1.28.0', require: false
16
+ gem 'rubocop-rake', '~> 0.6.0', require: false
17
+ gem 'rubocop-rspec', '~> 2.10.0', require: false
18
+ end unless without.include? 'lint'
19
+
20
+ group :coverage do
21
+ gem 'deep-cover-core', '~> 1.1.0', require: false
22
+ gem 'simplecov', '~> 0.21.0', require: false
23
+ end unless without.include? 'coverage'
data/LICENSE.adoc CHANGED
@@ -1,6 +1,6 @@
1
1
  .The MIT License
2
2
  ....
3
- Copyright (C) 2016 OpenDevise Inc. (on behalf of the Asciidoctor Project)
3
+ Copyright (C) 2016-2021 OpenDevise Inc. and the individual contributors to {project-name}.
4
4
 
5
5
  Permission is hereby granted, free of charge, to any person obtaining a copy
6
6
  of this software and associated documentation files (the "Software"), to deal
data/README.adoc CHANGED
@@ -1,6 +1,6 @@
1
1
  = {project-name} (Markdown to AsciiDoc)
2
2
  Dan Allen <https://github.com/mojavelinux>
3
- v1.0.0, 2018-11-07
3
+ v2.0.1, 2022-06-29
4
4
  // Aliases:
5
5
  :project-name: Kramdown AsciiDoc
6
6
  :project-handle: kramdown-asciidoc
@@ -19,48 +19,43 @@ ifdef::env-github[]
19
19
  :tip-caption: :bulb:
20
20
  endif::[]
21
21
  // URIs:
22
- :uri-repo: https://github.com/asciidoctor/kramdown-asciidoc
23
- :uri-asciidoc: https://asciidoctor.org/docs/what-is-asciidoc/#what-is-asciidoc
24
- :uri-asciidoctor: https://asciidoctor.org
25
- :uri-kramdown: https://kramdown.gettalong.org
26
- :uri-rvm: https://rvm.io
27
- :uri-rvm-install: https://rvm.io/rvm/install
28
- :uri-api-docs: https://www.rubydoc.info/github/asciidoctor/kramdown-asciidoc/master
29
- :uri-ci-appveyor: https://ci.appveyor.com/project/asciidoctor/kramdown-asciidoc
30
- :img-uri-ci-appveyor: https://ci.appveyor.com/api/projects/status/2pwvdbcoeux1ifb5/branch/master?svg=true
31
- :uri-ci-travis: https://travis-ci.org/asciidoctor/kramdown-asciidoc
32
- :img-uri-ci-travis: https://img.shields.io/travis/asciidoctor/kramdown-asciidoc/master.svg
33
- :uri-gem: https://rubygems.org/gems/kramdown-asciidoc
34
- :img-uri-gem: https://img.shields.io/gem/v/kramdown-asciidoc.svg?label=gem
22
+ :url-repo: https://github.com/asciidoctor/kramdown-asciidoc
23
+ :url-asciidoc: https://asciidoctor.org/docs/what-is-asciidoc/#what-is-asciidoc
24
+ :url-asciidoctor: https://asciidoctor.org
25
+ :url-kramdown: https://kramdown.gettalong.org
26
+ :url-rvm: https://rvm.io
27
+ :url-rvm-install: https://rvm.io/rvm/install
28
+ :url-api-docs: https://www.rubydoc.info/github/asciidoctor/kramdown-asciidoc/master
29
+ :url-gem: https://rubygems.org/gems/kramdown-asciidoc
30
+ :img-url-gem: https://img.shields.io/gem/v/kramdown-asciidoc.svg?label=gem
35
31
 
36
32
  ifdef::status[]
37
- image:{img-uri-gem}[Gem Version,link={uri-gem}]
38
- image:{img-uri-ci-travis}[Build Status (Travis CI),link={uri-ci-travis}]
39
- image:{img-uri-ci-appveyor}[Build Status (AppVeyor),link={uri-ci-appveyor}]
33
+ image:{img-url-gem}[Gem Version,link={url-gem}]
34
+ image:{url-repo}/workflows/CI/badge.svg[Build Status (GitHub Actions),link={url-repo}/actions?query=workflow%3ACI+branch%3Amain]
40
35
  endif::[]
41
36
 
42
- {uri-repo}[{project-name}] (gem: *{project-handle}*, command: `kramdoc`) is a {uri-kramdown}[kramdown] extension for converting Markdown documents to {uri-asciidoc}[AsciiDoc].
43
- Notably, the converter generates modern AsciiDoc syntax suitable for use with {uri-asciidoctor}[Asciidoctor].
37
+ {url-repo}[{project-name}] (gem: *{project-handle}*, command: `kramdoc`) is a {url-kramdown}[kramdown] extension for converting Markdown documents to {url-asciidoc}[AsciiDoc].
38
+ Notably, the converter generates modern AsciiDoc syntax suitable for use with {url-asciidoctor}[Asciidoctor].
44
39
 
45
40
  == Prerequisites
46
41
 
47
42
  To install and run {project-name}, you need Ruby 2.3 or better installed and a few RubyGems (aka gems).
48
- We'll explain how to install the gems in the next section.
43
+ The instructions for installing the gems is covered in the next section.
49
44
 
50
45
  To check whether you have Ruby installed, and which version, run the following command:
51
46
 
52
47
  $ ruby -v
53
48
 
54
- If Ruby is not installed, you can install it using {uri-rvm}[RVM] (or, if you prefer, the package manager for your system).
49
+ If Ruby is not installed, you can install it using {url-rvm}[RVM] (or, if you prefer, the package manager for your system).
55
50
  We generally recommend using RVM because it allows you to install gems without requiring elevated privileges or messing with system libraries.
56
51
 
57
52
  == Installation
58
53
 
59
- {project-name} is published to RubyGems.org as a pre-release gem named *{project-handle}*.
54
+ {project-name} is published to RubyGems.org as a gem named *{project-handle}*.
60
55
 
61
- You can install the pre-release version using the following command:
56
+ You can install the latest version of the gem using the following command:
62
57
 
63
- $ gem install kramdown-asciidoc --pre
58
+ $ gem install kramdown-asciidoc
64
59
 
65
60
  Installing this gem makes the `kramdoc` command available on your $PATH.
66
61
 
@@ -91,7 +86,7 @@ To see all the options the `kramdoc` command accepts, pass the `-h` option to th
91
86
 
92
87
  For example, you can inject attributes (key/value pairs) into the header of the AsciiDoc output document using the `-a` option.
93
88
 
94
- $ kramdoc -a product-name="ACME Cloud" -a hide-uri-scheme sample.md
89
+ $ kramdoc -a product-name="ACME Cloud" -a hide-url-scheme sample.md
95
90
 
96
91
  Another use for attributes is setting the shared images directory, which is covered in the next section.
97
92
 
@@ -164,7 +159,7 @@ If these values do not match the defaults in AsciiDoc, the `idprefix` and/or `id
164
159
 
165
160
  == API
166
161
 
167
- In additional to the command-line interface, {project-name} also provides a porcelain API (see {uri-api-docs}[API docs]).
162
+ In additional to the command-line interface, {project-name} also provides a porcelain API (see {url-api-docs}[API docs]).
168
163
  We use the term "`porcelain`" because the API hides the details of registering the converter, preprocessing the Markdown document, parsing the document with kramdown, and calling the converter method to transform the parse tree to AsciiDoc.
169
164
 
170
165
  The API consists of two static methods in the Kramdoc module:
@@ -220,7 +215,7 @@ Kramdoc.convert markdown, to: 'result.adoc'
220
215
 
221
216
  The input string is automatically converted to UTF-8.
222
217
 
223
- For more information about the API, refer to the {uri-api-docs}[API documentation].
218
+ For more information about the API, refer to the {url-api-docs}[API documentation].
224
219
 
225
220
  == Development
226
221
 
@@ -229,10 +224,10 @@ Follow the instructions below to learn how to clone the source and run the appli
229
224
 
230
225
  === Retrieve the source code
231
226
 
232
- Simply copy the {uri-repo}[GitHub repository URL] and pass it to the `git clone` command:
227
+ Simply copy the {url-repo}[GitHub repository URL] and pass it to the `git clone` command:
233
228
 
234
229
  [subs=attributes+]
235
- $ git clone {uri-repo}
230
+ $ git clone {url-repo}
236
231
 
237
232
  Next, switch to the project directory:
238
233
 
@@ -241,9 +236,9 @@ Next, switch to the project directory:
241
236
 
242
237
  === Prepare RVM (optional)
243
238
 
244
- We recommend using {uri-rvm}[RVM] when developing applications with Ruby.
239
+ We recommend using {url-rvm}[RVM] when developing applications with Ruby.
245
240
  We like RVM because it keeps the dependencies required by the project isolated from the rest of your system.
246
- Follow the {uri-rvm-install}[installation instructions] on the RVM site to setup RVM and install Ruby.
241
+ Follow the {url-rvm-install}[installation instructions] on the RVM site to setup RVM and install Ruby.
247
242
 
248
243
  Once you have RVM setup, switch to the RVM-managed version of Ruby recommended by the project using this command:
249
244
 
@@ -372,7 +367,7 @@ To avoid having to do this, or make the `kramdoc` command available from anywher
372
367
 
373
368
  == Copyright
374
369
 
375
- Copyright (C) 2016-2018 OpenDevise Inc. (on behalf of the Asciidoctor Project).
370
+ Copyright (C) 2016-2021 OpenDevise Inc. and the individual contributors to {project-name}.
376
371
  Free use of this software is granted under the terms of the MIT License.
377
372
 
378
373
  See the link:LICENSE.adoc[LICENSE] file for details.
data/bin/kramdoc CHANGED
@@ -1,11 +1,11 @@
1
1
  #!/usr/bin/env ruby
2
+ # frozen_string_literal: true
2
3
 
3
- if File.exist? (kramdown_asciidoc = File.absolute_path '../lib/kramdown-asciidoc', __dir__)
4
+ if File.file? (kramdown_asciidoc = File.join (File.dirname __dir__), 'lib/kramdown-asciidoc.rb')
4
5
  require kramdown_asciidoc
5
6
  else
6
7
  require 'kramdown-asciidoc'
7
8
  end
8
-
9
9
  require 'kramdown-asciidoc/cli'
10
10
 
11
11
  exit Kramdown::AsciiDoc::Cli.run
@@ -25,16 +25,16 @@ Gem::Specification.new do |s|
25
25
  rescue
26
26
  Dir['**/*']
27
27
  end
28
- #s.files = files.grep %r/^(?:lib\/.+|Gemfile|Rakefile|(?:CHANGELOG|CONTRIBUTING|LICENSE|README)\.adoc|#{s.name}\.gemspec)$/
29
- #s.test_files = files.grep %r/^(?:spec\/.+)$/
30
28
  s.files = files.grep %r/^(?:lib\/.+|Gemfile|(?:CHANGELOG|LICENSE|README)\.adoc|#{s.name}\.gemspec)$/
29
+ #s.test_files = files.grep %r/^spec\/./
31
30
  s.executables = ['kramdoc']
32
31
 
33
32
  s.require_paths = ['lib']
34
33
 
35
- s.add_runtime_dependency 'kramdown', '~> 1.17.0'
36
- s.add_development_dependency 'deep-cover-core', '~> 0.6.3'
37
- s.add_development_dependency 'rake', '~> 12.3.1'
38
- s.add_development_dependency 'rspec', '~> 3.8.0'
39
- s.add_development_dependency 'simplecov', '~> 0.16.1'
34
+ s.add_runtime_dependency 'kramdown', '~> 2.3.0'
35
+ s.add_runtime_dependency 'rexml', '~> 3.2.0'
36
+ s.add_runtime_dependency 'kramdown-parser-gfm', '~> 1.1.0'
37
+
38
+ s.add_development_dependency 'rake', '~> 13.0.0'
39
+ s.add_development_dependency 'rspec', '~> 3.11.0'
40
40
  end
data/lib/kramdoc.rb CHANGED
@@ -1 +1,3 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require 'kramdown-asciidoc'
@@ -1,4 +1,7 @@
1
- module Kramdown; module AsciiDoc
1
+ # frozen_string_literal: true
2
+
3
+ module Kramdown
4
+ module AsciiDoc
2
5
  DEFAULT_PARSER_OPTS = {
3
6
  auto_ids: false,
4
7
  hard_wrap: false,
@@ -9,7 +12,7 @@ module Kramdown; module AsciiDoc
9
12
  DEFAULT_PREPROCESSORS = [
10
13
  (Preprocessors.method :extract_front_matter),
11
14
  (Preprocessors.method :replace_toc),
12
- (Preprocessors.method :snap_leading_comment),
15
+ (Preprocessors.method :trim_before_leading_comment),
13
16
  ]
14
17
 
15
18
  # Converts a Markdown string to an AsciiDoc string and either returns the result or writes it to a file.
@@ -24,7 +27,10 @@ module Kramdown; module AsciiDoc
24
27
  # @option opts [Symbol] :wrap (:preserve) the line wrapping behavior to apply (:preserve, :ventilate, or :none).
25
28
  # @option opts [Integer] :heading_offset (0) the heading offset to apply to heading levels.
26
29
  # @option opts [Boolean] :auto_links (true) whether to allow raw URLs to be recognized as links.
27
- # @option opts [Hash] :attributes ({}) AsciiDoc attributes to add to the document header of the output document.
30
+ # @option opts [Hash] :attributes ({}) additional AsciiDoc attributes to add to header of output document; reserved
31
+ # attributes, like stem, may be overridden; some attributes may impact conversion, such as idprefix and idseparator
32
+ # @option opts [String] :imagesdir (nil) the prefix to remove from image references found in the Markdown document;
33
+ # if not specified, the value of the imagesdir attribute is used
28
34
  # @option opts [Symbol] :encode (true) whether to reencode the source to UTF-8.
29
35
  # @option opts [Array<Proc>] :preprocessors ([]) a list of preprocessors functions to execute on the cleaned Markdown source.
30
36
  # @option opts [Array<Proc>] :postprocessors ([]) a list of functions through which to run the output document.
@@ -79,7 +85,10 @@ module Kramdown; module AsciiDoc
79
85
  # @option opts [Symbol] :wrap (:preserve) the line wrapping behavior to apply (:preserve, :ventilate, or :none).
80
86
  # @option opts [Integer] :heading_offset (0) the heading offset to apply to heading levels.
81
87
  # @option opts [Boolean] :auto_links (true) whether to allow raw URLs to be recognized as links.
82
- # @option opts [Hash] :attributes ({}) AsciiDoc attributes to add to the document header of the output document.
88
+ # @option opts [Hash] :attributes ({}) additional AsciiDoc attributes to add to header of output document; reserved
89
+ # attributes, like stem, may be overridden; some attributes may impact conversion, such as idprefix and idseparator
90
+ # @option opts [String] :imagesdir (nil) the prefix to remove from image references found in the Markdown document;
91
+ # if not specified, the value of the imagesdir attribute is used
83
92
  # @option opts [Array<Proc>] :preprocessors ([]) a list of preprocessors functions to execute on the cleaned Markdown source.
84
93
  # @option opts [Array<Proc>] :postprocessors ([]) a list of functions through which to run the output document.
85
94
  # @option opts [Proc] :postprocess (nil) a function through which to run the output document (if :postprocessors is falsy).
@@ -92,7 +101,7 @@ module Kramdown; module AsciiDoc
92
101
  markdown_file = markdown_file.path
93
102
  encode = true
94
103
  else
95
- markdown = ::IO.read markdown_file, mode: 'r:UTF-8', newline: :universal
104
+ markdown = ::File.read markdown_file, mode: 'r:UTF-8', newline: :universal
96
105
  encode = false
97
106
  end
98
107
  if (to = opts[:to])
@@ -104,10 +113,11 @@ module Kramdown; module AsciiDoc
104
113
  convert markdown, (opts.merge to: to, encode: encode)
105
114
  end
106
115
 
107
- private
108
-
109
116
  CR = ?\r
110
117
  LF = ?\n
111
118
  TAB = ?\t
112
119
  UTF_8 = ::Encoding::UTF_8
113
- end; end
120
+
121
+ private_constant :CR, :LF, :TAB, :UTF_8
122
+ end
123
+ end
@@ -1,18 +1,21 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require 'optparse'
2
4
  require 'pathname'
3
5
 
4
- module Kramdown; module AsciiDoc
6
+ module Kramdown
7
+ module AsciiDoc
5
8
  autoload :VERSION, (::File.join __dir__, 'version.rb')
6
9
  class Cli
7
10
  def parse args
8
11
  options = {
9
- attributes: {}
12
+ attributes: {},
10
13
  }
11
14
 
12
15
  opt_parser = ::OptionParser.new do |opts|
13
16
  opts.program_name = 'kramdoc'
14
17
  opts.banner = <<~EOS
15
- Usage: #{opts.program_name} [OPTION]... FILE...
18
+ Usage: #{opts.program_name} [OPTION]... FILE
16
19
 
17
20
  Converts Markdown to AsciiDoc.
18
21
 
@@ -28,7 +31,7 @@ module Kramdown; module AsciiDoc
28
31
 
29
32
  opts.on '-a KEY[=VALUE]', '--attribute=KEY[=VALUE]', 'Set an attribute in the AsciiDoc document header (accepts: key, key!, or key=value)' do |attr|
30
33
  key, val = attr.split '=', 2
31
- val = '' unless val
34
+ val ||= ''
32
35
  options[:attributes][key] = val
33
36
  end
34
37
 
@@ -84,10 +87,8 @@ module Kramdown; module AsciiDoc
84
87
  if args.empty?
85
88
  opt_parser.warn 'Please specify a Markdown file to convert.'
86
89
  $stdout.write opt_parser.help
87
- return 1
88
- end
89
-
90
- if args.size == 1
90
+ 1
91
+ elsif args.size == 1
91
92
  options[:input_file] = args[0]
92
93
  [0, options]
93
94
  else
@@ -117,9 +118,10 @@ module Kramdown; module AsciiDoc
117
118
  ::Kramdoc.convert_file input_file, options
118
119
  end
119
120
  0
120
- rescue ::IOError => e
121
- $stderr.write %(kramdoc: #{e.message}\n)
121
+ rescue ::IOError
122
+ $stderr.write %(kramdoc: #{$!.message}\n)
122
123
  1
123
124
  end
124
125
  end
125
- end; end
126
+ end
127
+ end
@@ -1,5 +1,7 @@
1
- # encoding: UTF-8
2
- module Kramdown; module AsciiDoc
1
+ # frozen_string_literal: true
2
+
3
+ module Kramdown
4
+ module AsciiDoc
3
5
  class Converter < ::Kramdown::Converter::Base
4
6
  using CoreExt
5
7
 
@@ -45,12 +47,12 @@ module Kramdown; module AsciiDoc
45
47
  InvalidIdCharsRx = /&(?:[a-z][a-z]+\d{0,2}|#\d\d\d{0,4}|#x[\da-f][\da-f][\da-f]{0,3});|[^ \p{Word}\-.]+?/
46
48
  ListMarkerRx = /^[ \t]*(?:(?:-|\*\*{0,4}|\.\.{0,4}|\d+\.|[a-zA-Z]\.|[IVXivx]+\))[ \t]|.*?(?::::{0,2}|;;)(?:$|[ \t]))/
47
49
  MenuRefRx = /^([\p{Word}&].*?)\s>\s([\p{Word}&].*(?:\s>\s|$))+/
48
- ReplaceableTextRx = /[-=]>|<[-=]| -- |\p{Word}--\p{Word}|\*\*|\.\.\.|&\S+;|\{\p{Word}[\p{Word}-]*\}|(?:https?|ftp):\/\/\p{Word}|\((?:C|R|TM)\)/
50
+ ReplaceableTextRx = %r([-=]>|<[-=]| -- |\p{Word}--\p{Word}|\*\*|\.\.\.|&\S+;|\{\p{Word}[\p{Word}-]*\}|(?:https?|ftp)://\p{Word}|\((?:C|R|TM)\))
49
51
  SmartApostropheRx = /\b’\b/
50
- StopPunctRx = /(?<=\S[.;]|.\?|.!)\p{Blank}+/
52
+ StopPunctRx = /(?<=\S[.;]|.[?!])\p{Blank}+/
51
53
  TrailingSpaceRx = / +$/
52
54
  TypographicSymbolRx = /[“”‘’—–…]/
53
- UriSchemeRx = /(?:https?|ftp):\/\/\p{Word}/
55
+ UriSchemeRx = %r((?:https?|ftp)://\p{Word})
54
56
  WordishRx = /[\p{Word};:<>&]/
55
57
  WordRx = /\p{Word}/
56
58
  XmlCommentRx = /\A<!--(.*)-->\Z/m
@@ -67,13 +69,13 @@ module Kramdown; module AsciiDoc
67
69
  @lazy_ids = opts[:lazy_ids]
68
70
  if @auto_ids || @lazy_ids
69
71
  if @auto_ids
70
- unless (@id_pre = opts[:auto_id_prefix]) == '_'
72
+ @id_pre = opts[:auto_id_prefix]
73
+ sep = opts[:auto_id_separator] || '-'
74
+ if @lazy_ids
71
75
  # NOTE only need to set idprefix when lazy_ids is set since otherwise all IDs are explicit
72
- @attributes['idprefix'] = @id_pre if @lazy_ids
73
- end
74
- unless (sep = opts[:auto_id_separator] || '-') == '_'
76
+ @attributes['idprefix'] = @id_pre unless @id_pre == '_'
75
77
  # NOTE only need to set idseparator when lazy_ids is set since otherwise all IDs are explicit
76
- @attributes['idseparator'] = sep if @lazy_ids
78
+ @attributes['idseparator'] = sep unless sep == '_'
77
79
  end
78
80
  else
79
81
  @id_pre = @attributes['idprefix'] || '_'
@@ -88,6 +90,7 @@ module Kramdown; module AsciiDoc
88
90
  @id_sep_replace = sep_replace
89
91
  end
90
92
  @ids_seen = {}
93
+ @footnote_ids = ::Set.new
91
94
  @auto_links = opts.fetch :auto_links, true
92
95
  @heading_offset = opts[:heading_offset] || 0
93
96
  @imagesdir = opts[:imagesdir] || @attributes['imagesdir']
@@ -166,8 +169,7 @@ module Kramdown; module AsciiDoc
166
169
  # Kramdown incorrectly uses the term header for headings
167
170
  alias convert_header convert_heading
168
171
 
169
- def convert_blank el, opts
170
- end
172
+ def convert_blank el, opts; end
171
173
 
172
174
  def convert_p el, opts
173
175
  (writer = opts[:writer]).start_block
@@ -204,7 +206,7 @@ module Kramdown; module AsciiDoc
204
206
  if contents[0].start_with?(*ADMON_MARKERS_ASCIIDOC) && !(contents.include? '')
205
207
  writer.add_lines contents
206
208
  else
207
- if contents.size > 1 && (contents[-1].start_with? '-- ')
209
+ if contents.size > 1 && ::String === (last_line = contents[-1]) && (last_line.start_with? '-- ')
208
210
  attribution = (attribution_line = contents.pop).slice 3, attribution_line.length
209
211
  writer.add_line %([,#{attribution}])
210
212
  # NOTE there will be at least one non-blank line, but coerce .to_s just to be safe
@@ -226,25 +228,26 @@ module Kramdown; module AsciiDoc
226
228
  writer.start_block
227
229
  end
228
230
  lines = el.value.rstrip.split LF
231
+ first_line = lines[0]
229
232
  if (lang = el.attr['class'])
230
233
  # NOTE Kramdown always prefixes class with language-
231
234
  # TODO remap lang if requested
232
- writer.add_line %([source,#{lang = lang.slice 9, lang.length}])
233
- elsif (prompt = lines[0].start_with? '$ ')
234
- writer.add_line %([source,#{lang = 'console'}]) if lines.include? ''
235
+ writer.add_line %([,#{lang = lang.slice 9, lang.length}])
236
+ elsif (prompt = first_line && (first_line.start_with? '$ '))
237
+ writer.add_line %([,#{lang = 'console'}]) if lines.include? ''
235
238
  end
236
239
  if lang || (el.options[:fenced] && !prompt)
237
240
  writer.add_line '----'
238
241
  writer.add_lines lines
239
242
  writer.add_line '----'
240
- elsif !prompt && ((lines.include? '') || (ListMarkerRx.match? lines[0]))
243
+ elsif !prompt && ((lines.include? '') || (first_line && (ListMarkerRx.match? first_line)))
241
244
  writer.add_line '....'
242
245
  writer.add_lines lines
243
246
  writer.add_line '....'
244
247
  else
245
248
  # NOTE clear the list continuation as it isn't required
246
249
  writer.clear_line if writer.current_line == '+'
247
- writer.add_line lines.map {|l| %( #{l}) }
250
+ writer.add_line(lines.map {|l| %( #{l}) })
248
251
  end
249
252
  end
250
253
 
@@ -263,8 +266,8 @@ module Kramdown; module AsciiDoc
263
266
  block = true
264
267
  end
265
268
  macro_attrs = [nil]
266
- if (alt_text = el.attr['alt'])
267
- macro_attrs[0] = alt_text unless alt_text.empty?
269
+ if (alt_text = el.attr['alt']) && !alt_text.empty?
270
+ macro_attrs[0] = alt_text
268
271
  end
269
272
  if (width = el.attr['width'])
270
273
  macro_attrs << width
@@ -293,7 +296,7 @@ module Kramdown; module AsciiDoc
293
296
  end
294
297
  end
295
298
 
296
- def convert_ul el, opts
299
+ def _convert_list el, opts
297
300
  kin = el.type == :dl ? :dlist : :list
298
301
  (writer = opts[:writer]).start_list (parent = opts[:parent]).type == :dd || parent.options[:compound], kin
299
302
  traverse el, opts
@@ -301,15 +304,16 @@ module Kramdown; module AsciiDoc
301
304
  writer.add_blank_line if writer.in_list? && opts[:next]
302
305
  end
303
306
 
304
- alias convert_ol convert_ul
305
- alias convert_dl convert_ul
307
+ alias convert_ul _convert_list
308
+ alias convert_ol _convert_list
309
+ alias convert_dl _convert_list
306
310
 
307
311
  def convert_li el, opts
308
312
  writer = opts[:writer]
309
313
  writer.add_blank_line if (prev = opts[:prev]) && prev.options[:compound]
310
314
  marker = opts[:parent].type == :ol ? '.' : '*'
311
315
  indent = (level = writer.list_level) - 1
312
- if (children = el.children)[0].type == :p
316
+ if !(children = el.children).empty? && children[0].type == :p
313
317
  primary, remaining = [(children = children.dup).shift, children]
314
318
  primary_lines = compose_text [primary], parent: el, strip: true, split: true, wrap: @wrap
315
319
  else
@@ -320,7 +324,7 @@ module Kramdown; module AsciiDoc
320
324
  writer.add_lines primary_lines
321
325
  unless remaining.empty?
322
326
  if remaining.find {|n| (type = n.type) == :blank ? nil : ((BLOCK_TYPES.include? type) ? true : break) }
323
- el.options[:compound] = true
327
+ el.options[:compound] = true
324
328
  end
325
329
  traverse remaining, (opts.merge parent: el)
326
330
  end
@@ -402,7 +406,7 @@ module Kramdown; module AsciiDoc
402
406
  opts[:writer].add_lines table_buffer
403
407
  end
404
408
 
405
- def convert_hr el, opts
409
+ def convert_hr _el, opts
406
410
  (writer = opts[:writer]).start_block
407
411
  writer.add_line '\'\'\''
408
412
  end
@@ -411,11 +415,11 @@ module Kramdown; module AsciiDoc
411
415
  if (url = el.attr['href']).start_with? '#'
412
416
  opts[:writer].append %(<<#{url.slice 1, url.length},#{compose_text el, strip: true}>>)
413
417
  elsif url.start_with? 'https://', 'http://'
414
- if (children = el.children).size == 1 && (child_i = el.children[0]).type == :img
418
+ if (children = el.children).size == 1 && (child_i = children[0]).type == :img
415
419
  convert_img child_i, parent: opts[:parent], index: 0, url: url, writer: opts[:writer]
416
420
  else
417
421
  bare = ((text = compose_text el, strip: true).chomp '/') == (url.chomp '/')
418
- url = url.gsub '__', '%5F%5F' if (url.include? '__')
422
+ url = url.gsub '__', '%5F%5F' if url.include? '__'
419
423
  opts[:writer].append bare ? url : %(#{url}[#{text.gsub ']', '\]'}])
420
424
  end
421
425
  elsif url.end_with? '.md'
@@ -425,7 +429,7 @@ module Kramdown; module AsciiDoc
425
429
  else
426
430
  opts[:writer].append %(link:#{url}[#{(compose_text el, strip: true).gsub ']', '\]'}])
427
431
  end
428
- end
432
+ end
429
433
 
430
434
  def convert_codespan el, opts
431
435
  attrlist, mark = '', '`'
@@ -446,9 +450,10 @@ module Kramdown; module AsciiDoc
446
450
  text = el.value
447
451
  pass = (replaceable? text) ? :shorthand : nil
448
452
  pass = :macro if text.include? '++'
449
- if pass == :shorthand
453
+ case pass
454
+ when :shorthand
450
455
  opts[:writer].append %(#{mark}+#{text}+#{mark})
451
- elsif pass == :macro
456
+ when :macro
452
457
  opts[:writer].append %(#{mark}pass:c[#{text}]#{mark})
453
458
  else
454
459
  opts[:writer].append %(#{attrlist}#{mark}#{text}#{mark})
@@ -483,13 +488,17 @@ module Kramdown; module AsciiDoc
483
488
  next_el && next_el.type == :text && (WordRx.match? next_el.value.chr)
484
489
  end
485
490
 
491
+ def convert_abbreviation el, opts
492
+ opts[:writer].append el.value
493
+ end
494
+
486
495
  def convert_text el, opts
487
496
  text = escape_replacements el.value
488
497
  if text.include? '++'
489
498
  @attributes['pp'] = '{plus}{plus}'
490
499
  text = text.gsub '++', '{pp}'
491
500
  end
492
- if (current_line = (writer = opts[:writer]).current_line).to_s.empty?
501
+ if (writer = opts[:writer]).current_line.to_s.empty?
493
502
  writer.append text.lstrip
494
503
  else
495
504
  writer.append text
@@ -519,15 +528,19 @@ module Kramdown; module AsciiDoc
519
528
  else
520
529
  writer.append %(#{(writer.current_line.end_with? ' ') ? '' : ' '}+)
521
530
  end
522
- if el.options[:html_tag]
523
- writer.add_blank_line unless (next_el = to_element opts[:next]).type == :text && (next_el.value.start_with? LF)
524
- end
531
+ writer.add_blank_line if el.options[:html_tag] && ((next_el = to_element opts[:next]).type != :text || !(next_el.value.start_with? LF))
525
532
  end
526
533
 
527
534
  def convert_entity el, opts
528
535
  opts[:writer].append RESOLVE_ENTITY_TABLE[el.value.code_point] || el.options[:original]
529
536
  end
530
537
 
538
+ def convert_footnote el, opts
539
+ id = el.options[:name]
540
+ composed_text = (@footnote_ids.add? id) ? ((compose_text el.value).gsub ']', '\]') : ''
541
+ opts[:writer].append %(footnote:#{id}[#{composed_text}])
542
+ end
543
+
531
544
  def convert_smart_quote el, opts
532
545
  opts[:writer].append SMART_QUOTE_ENTITY_TO_MARKUP[el.value]
533
546
  end
@@ -538,7 +551,11 @@ module Kramdown; module AsciiDoc
538
551
  end
539
552
 
540
553
  def convert_html_element el, opts
541
- if (tag = el.value) == 'div' && (child_i = el.children[0]) && child_i.options[:transparent] && (child_i_i = child_i.children[0])
554
+ if (tag = el.value) == 'script'
555
+ opts[:writer].start_block
556
+ opts[:writer].add_lines ['++++', '<script>', el.children[0].value.strip, '</script>', '++++']
557
+ return
558
+ elsif tag == 'div' && (child_i = el.children[0]) && child_i.options[:transparent] && (child_i_i = child_i.children[0])
542
559
  if child_i_i.value == 'span' && ((role = el.attr['class'].to_s).start_with? 'note') && child_i_i.attr['class'] == 'notetitle'
543
560
  marker = ADMON_FORMATTED_MARKERS[(to_element child_i_i.children[0]).value] || 'Note'
544
561
  lines = compose_text (child_i.children.drop 1), parent: child_i, strip: true, split: true, wrap: @wrap
@@ -583,7 +600,7 @@ module Kramdown; module AsciiDoc
583
600
  lines = val.split LF
584
601
  end
585
602
  #siblings = (parent = opts[:parent]) ? parent.children : []
586
- if (el.options[:category] == :block)# || (!opts[:result][-1] && siblings[-1] == el)
603
+ if el.options[:category] == :block # || (!opts[:result][-1] && siblings[-1] == el)
587
604
  writer.start_block
588
605
  if lines.empty?
589
606
  writer.add_line '//'
@@ -611,10 +628,24 @@ module Kramdown; module AsciiDoc
611
628
  end
612
629
  end
613
630
 
631
+ def convert_math el, opts
632
+ writer = opts[:writer]
633
+ @attributes['stem'] = 'latexmath'
634
+ if el.options[:category] == :span
635
+ writer.append %(stem:[#{el.value.gsub ']', '\]'}])
636
+ else
637
+ writer.start_block
638
+ writer.add_line '[stem]'
639
+ writer.add_line '++++'
640
+ writer.add_lines el.value.rstrip.split LF
641
+ writer.add_line '++++'
642
+ end
643
+ end
644
+
614
645
  private
615
646
 
616
647
  def extract_prologue el, opts
617
- if (child_i = to_element (children = el.children)[0]).type == :xml_comment
648
+ if (to_element (children = el.children)[0]).type == :xml_comment
618
649
  (prologue_el = el.dup).children = children.take_while {|child| child.type == :xml_comment || child.type == :blank }
619
650
  (el = el.dup).children = children.drop prologue_el.children.size
620
651
  traverse prologue_el, (opts.merge writer: (prologue_writer = Writer.new))
@@ -692,9 +723,9 @@ module Kramdown; module AsciiDoc
692
723
  end
693
724
  end
694
725
  if ventilate
695
- result.map {|line|
696
- (line.start_with? '//') || !(STOP_PUNCTUATION.any? {|punc| line.include? punc }) ? line : (line.gsub StopPunctRx, LF)
697
- }.join LF
726
+ result.map do |l|
727
+ (l.start_with? '//') || !(STOP_PUNCTUATION.any? {|punc| l.include? punc }) ? l : (l.gsub StopPunctRx, LF)
728
+ end.join LF
698
729
  else
699
730
  result.join LF
700
731
  end
@@ -741,4 +772,5 @@ module Kramdown; module AsciiDoc
741
772
  @ids_seen[id] = idx || UNIQUE_ID_START_INDEX
742
773
  end
743
774
  end
744
- end; end
775
+ end
776
+ end
@@ -1,5 +1,13 @@
1
- module Kramdown; module AsciiDoc; module CoreExt
2
- refine Regexp do
3
- alias match? === unless method_defined? :match? # nocov
1
+ # frozen_string_literal: true
2
+
3
+ module Kramdown
4
+ module AsciiDoc
5
+ module CoreExt
6
+ refine Regexp do
7
+ # rubocop:disable Style/Alias
8
+ alias match? === unless method_defined? :match? # nocov
9
+ # rubocop:enable Style/Alias
10
+ end
4
11
  end
5
- end; end; end
12
+ end
13
+ end
@@ -0,0 +1,14 @@
1
+ # frozen_string_literal: true
2
+
3
+ require 'yaml'
4
+
5
+ autoload :Date, 'time'
6
+ autoload :Time, 'time'
7
+
8
+ unless (YAML.method :safe_load).parameters.include? [:key, :aliases]
9
+ YAML.singleton_class.prepend (Module.new do
10
+ def safe_load yaml, permitted_classes: [], permitted_symbols: [], aliases: false, filename: nil
11
+ super yaml, permitted_classes, permitted_symbols, aliases, filename
12
+ end
13
+ end)
14
+ end
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  class Kramdown::Parser::Base
2
4
  # Overload the parse method to force value of the :auto_ids option to false.
3
5
  #
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  class Kramdown::Parser::Html::ElementConverter
2
4
  # Overload the convert_br method to add the :html_tag option to indicate this element originates from an HTML tag.
3
5
  #
@@ -1,4 +1,7 @@
1
- module Kramdown; module AsciiDoc
1
+ # frozen_string_literal: true
2
+
3
+ module Kramdown
4
+ module AsciiDoc
2
5
  module Preprocessors
3
6
  # Skims off the front matter from the top of the Markdown source and store the data in the provided attributes Hash.
4
7
  #
@@ -15,7 +18,7 @@ module Kramdown; module AsciiDoc
15
18
  end
16
19
  return source unless line && line.chomp == '---' && !(front_matter.include? ?\n)
17
20
  lines.shift while (line = lines[0]) && line == ?\n
18
- (::YAML.load front_matter.join).each do |key, val|
21
+ (::YAML.safe_load front_matter.join, permitted_classes: [::Date, ::Time]).each do |key, val|
19
22
  if key == 'layout'
20
23
  attributes['page-layout'] = val unless val == 'default'
21
24
  else
@@ -43,22 +46,21 @@ module Kramdown; module AsciiDoc
43
46
  end
44
47
  end
45
48
 
46
- # Snaps the leading XML comment to the start of the Markdown source.
49
+ # Trims space characters that precede a leading XML comment in the Markdown source.
47
50
  #
48
51
  # @param markdown [String] the Markdown source to process.
49
52
  # @param attributes [Hash] a map of AsciiDoc attributes to set on the output document.
50
53
  #
51
- # @return [String] the Markdown source with whitespace the precedes a leading XML comment removed.
52
- def self.snap_leading_comment markdown, attributes
54
+ # @return [String] the Markdown source with the space characters preceding a leading XML comment removed.
55
+ def self.trim_before_leading_comment markdown, _attributes
53
56
  (markdown.start_with? ' ', TAB) && (markdown.lstrip.start_with? '<!--') ? markdown.lstrip : markdown
54
57
  end
55
58
 
56
- private
57
-
58
59
  TAB = ?\t
59
-
60
60
  TocDirectiveTip = '<!-- TOC '
61
+ TocDirectiveRx = %r(^<!-- TOC .*<!-- /TOC -->)m
61
62
 
62
- TocDirectiveRx = /^<!-- TOC .*<!-- \/TOC -->/m
63
+ private_constant :TAB, :TocDirectiveTip, :TocDirectiveRx
63
64
  end
64
- end; end
65
+ end
66
+ end
@@ -1,3 +1,7 @@
1
- module Kramdown; module AsciiDoc
2
- VERSION = '1.0.0'
3
- end; end
1
+ # frozen_string_literal: true
2
+
3
+ module Kramdown
4
+ module AsciiDoc
5
+ VERSION = '2.0.1'
6
+ end
7
+ end
@@ -1,4 +1,7 @@
1
- module Kramdown; module AsciiDoc
1
+ # frozen_string_literal: true
2
+
3
+ module Kramdown
4
+ module AsciiDoc
2
5
  class Writer
3
6
  LF = ?\n
4
7
 
@@ -48,7 +51,6 @@ module Kramdown; module AsciiDoc
48
51
  parent_body, @block_delimiter, @block_separator, @list_level = @nesting_stack.pop
49
52
  @body = (parent_body + @body) << @block_delimiter
50
53
  @block_delimiter = nil
51
- nil
52
54
  end
53
55
 
54
56
  # Q: perhaps do_in_list that takes a block?
@@ -130,4 +132,5 @@ module Kramdown; module AsciiDoc
130
132
  (header.empty? ? @body : (header + (@body.empty? ? [] : [''] + @body))).join LF
131
133
  end
132
134
  end
133
- end; end
135
+ end
136
+ end
@@ -1,7 +1,10 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require 'kramdown'
2
4
  require_relative 'kramdown-asciidoc/kramdown_ext/parser/base'
3
5
  require_relative 'kramdown-asciidoc/kramdown_ext/parser/html'
4
6
  require_relative 'kramdown-asciidoc/core_ext/regexp/is_match'
7
+ require_relative 'kramdown-asciidoc/core_ext/yaml'
5
8
  require_relative 'kramdown-asciidoc/preprocessors'
6
9
  require_relative 'kramdown-asciidoc/writer'
7
10
  require_relative 'kramdown-asciidoc/converter'
@@ -11,4 +14,3 @@ Kramdown::Converter::Asciidoc = Kramdown::AsciiDoc::Converter
11
14
  # add Kramdoc alias
12
15
  Kramdoc = Kramdown::AsciiDoc
13
16
  autoload :Pathname, 'pathname'
14
- autoload :YAML, 'yaml'
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: kramdown-asciidoc
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0
4
+ version: 2.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Dan Allen
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-11-07 00:00:00.000000000 Z
11
+ date: 2022-06-29 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: kramdown
@@ -16,70 +16,70 @@ dependencies:
16
16
  requirements:
17
17
  - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: 1.17.0
19
+ version: 2.3.0
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - "~>"
25
25
  - !ruby/object:Gem::Version
26
- version: 1.17.0
26
+ version: 2.3.0
27
27
  - !ruby/object:Gem::Dependency
28
- name: deep-cover-core
28
+ name: rexml
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
31
  - - "~>"
32
32
  - !ruby/object:Gem::Version
33
- version: 0.6.3
34
- type: :development
33
+ version: 3.2.0
34
+ type: :runtime
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
38
  - - "~>"
39
39
  - !ruby/object:Gem::Version
40
- version: 0.6.3
40
+ version: 3.2.0
41
41
  - !ruby/object:Gem::Dependency
42
- name: rake
42
+ name: kramdown-parser-gfm
43
43
  requirement: !ruby/object:Gem::Requirement
44
44
  requirements:
45
45
  - - "~>"
46
46
  - !ruby/object:Gem::Version
47
- version: 12.3.1
48
- type: :development
47
+ version: 1.1.0
48
+ type: :runtime
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
52
  - - "~>"
53
53
  - !ruby/object:Gem::Version
54
- version: 12.3.1
54
+ version: 1.1.0
55
55
  - !ruby/object:Gem::Dependency
56
- name: rspec
56
+ name: rake
57
57
  requirement: !ruby/object:Gem::Requirement
58
58
  requirements:
59
59
  - - "~>"
60
60
  - !ruby/object:Gem::Version
61
- version: 3.8.0
61
+ version: 13.0.0
62
62
  type: :development
63
63
  prerelease: false
64
64
  version_requirements: !ruby/object:Gem::Requirement
65
65
  requirements:
66
66
  - - "~>"
67
67
  - !ruby/object:Gem::Version
68
- version: 3.8.0
68
+ version: 13.0.0
69
69
  - !ruby/object:Gem::Dependency
70
- name: simplecov
70
+ name: rspec
71
71
  requirement: !ruby/object:Gem::Requirement
72
72
  requirements:
73
73
  - - "~>"
74
74
  - !ruby/object:Gem::Version
75
- version: 0.16.1
75
+ version: 3.11.0
76
76
  type: :development
77
77
  prerelease: false
78
78
  version_requirements: !ruby/object:Gem::Requirement
79
79
  requirements:
80
80
  - - "~>"
81
81
  - !ruby/object:Gem::Version
82
- version: 0.16.1
82
+ version: 3.11.0
83
83
  description: A kramdown extension for converting Markdown documents to AsciiDoc.
84
84
  email:
85
85
  - dan.j.allen@gmail.com
@@ -100,6 +100,7 @@ files:
100
100
  - lib/kramdown-asciidoc/cli.rb
101
101
  - lib/kramdown-asciidoc/converter.rb
102
102
  - lib/kramdown-asciidoc/core_ext/regexp/is_match.rb
103
+ - lib/kramdown-asciidoc/core_ext/yaml.rb
103
104
  - lib/kramdown-asciidoc/kramdown_ext/parser/base.rb
104
105
  - lib/kramdown-asciidoc/kramdown_ext/parser/html.rb
105
106
  - lib/kramdown-asciidoc/preprocessors.rb
@@ -128,8 +129,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
128
129
  - !ruby/object:Gem::Version
129
130
  version: '0'
130
131
  requirements: []
131
- rubyforge_project:
132
- rubygems_version: 2.7.8
132
+ rubygems_version: 3.3.7
133
133
  signing_key:
134
134
  specification_version: 4
135
135
  summary: A Markdown to AsciiDoc converter based on kramdown