Sha256: c650dfde69f6c0c89960578e7b8fefd0c4ef776f84922f0435b151d5731483bc

Contents?: true

Size: 421 Bytes

Versions: 12

Compression:

Stored size: 421 Bytes

Contents

require 'yard'

# Template helper to modify processing of links in HTML generated from our
# markdown files.
module LocalLinkHelper
  # Rewrites links to (assumed local) markdown files so they're processed as
  # {file: } directives.
  def resolve_links(text)
    text = text.gsub(%r{<a href="([^"]*.md)">([^<]*)</a>}, '{file:\1 \2}')
    super text
  end
end

YARD::Templates::Template.extra_includes << LocalLinkHelper

Version data entries

12 entries across 12 versions & 1 rubygems

Version Path
reek-3.3.1 docs/yard_plugin.rb
reek-3.3.0 docs/yard_plugin.rb
reek-3.2.1 docs/yard_plugin.rb
reek-3.2 docs/yard_plugin.rb
reek-3.1 docs/yard_plugin.rb
reek-3.0.4 docs/yard_plugin.rb
reek-3.0.3 docs/yard_plugin.rb
reek-3.0.2 docs/yard_plugin.rb
reek-3.0.1 docs/yard_plugin.rb
reek-3.0.0 docs/yard_plugin.rb
reek-2.2.1 docs/yard_plugin.rb
reek-2.2.0 docs/yard_plugin.rb