hoe-markdown 1.3.0 → 1.5.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.github/workflows/ci.yml +28 -0
- data/CHANGELOG.md +14 -0
- data/README.md +6 -1
- data/lib/hoe/markdown/standalone.rb +1 -1
- data/lib/hoe/markdown/util.rb +6 -0
- data/lib/hoe/markdown/version.rb +1 -1
- data/lib/hoe/markdown.rb +2 -1
- metadata +4 -3
    
        checksums.yaml
    CHANGED
    
    | @@ -1,7 +1,7 @@ | |
| 1 1 | 
             
            ---
         | 
| 2 2 | 
             
            SHA256:
         | 
| 3 | 
            -
              metadata.gz:  | 
| 4 | 
            -
              data.tar.gz:  | 
| 3 | 
            +
              metadata.gz: 9a0bdac1445c1aa33f1da6d0f7121b17dcc46d09bd2fbe3edb98cec7326608dc
         | 
| 4 | 
            +
              data.tar.gz: 84958c46a62b0b272e25e6f44f9fa83e3a1d1a7f2cbad019b722fc61eb0d2c5a
         | 
| 5 5 | 
             
            SHA512:
         | 
| 6 | 
            -
              metadata.gz:  | 
| 7 | 
            -
              data.tar.gz:  | 
| 6 | 
            +
              metadata.gz: 71d6a94280d257d7ae07796306f91a81aa85c0db35ff1a039a6293582c84f7a9dbe603934b64be0485e4f8fea3f088fc6e4be3bbaa742858bd43100496ea6c85
         | 
| 7 | 
            +
              data.tar.gz: 3259e4bd5ee0297111aa62937a49fc0011a06218c8d2de9e191ce417b29f3c51b298b3bd221715376e7d6521dc6ac2194cb8bee134d46a7cc026dc8c658321f5
         | 
| @@ -0,0 +1,28 @@ | |
| 1 | 
            +
            name: ci
         | 
| 2 | 
            +
            concurrency:
         | 
| 3 | 
            +
              group: "${{github.workflow}}-${{github.ref}}"
         | 
| 4 | 
            +
              cancel-in-progress: true
         | 
| 5 | 
            +
            on:
         | 
| 6 | 
            +
              workflow_dispatch:
         | 
| 7 | 
            +
              push:
         | 
| 8 | 
            +
                branches:
         | 
| 9 | 
            +
                  - main
         | 
| 10 | 
            +
              pull_request:
         | 
| 11 | 
            +
                types: [opened, synchronize]
         | 
| 12 | 
            +
                branches:
         | 
| 13 | 
            +
                  - '*'
         | 
| 14 | 
            +
             | 
| 15 | 
            +
            jobs:
         | 
| 16 | 
            +
              build:
         | 
| 17 | 
            +
                strategy:
         | 
| 18 | 
            +
                  fail-fast: false
         | 
| 19 | 
            +
                  matrix:
         | 
| 20 | 
            +
                    ruby: ["2.7", "3.0", "3.1", "3.2", "head"]
         | 
| 21 | 
            +
                runs-on: ubuntu-latest
         | 
| 22 | 
            +
                steps:
         | 
| 23 | 
            +
                  - uses: actions/checkout@v4
         | 
| 24 | 
            +
                  - uses: ruby/setup-ruby@v1
         | 
| 25 | 
            +
                    with:
         | 
| 26 | 
            +
                      ruby-version: ${{matrix.ruby}}
         | 
| 27 | 
            +
                      bundler-cache: true
         | 
| 28 | 
            +
                  - run: bundle exec rake
         | 
    
        data/CHANGELOG.md
    CHANGED
    
    | @@ -1,5 +1,19 @@ | |
| 1 1 | 
             
            # Hoe::Markdown CHANGELOG
         | 
| 2 2 |  | 
| 3 | 
            +
            ## v1.5.0 / 2023-10-10
         | 
| 4 | 
            +
             | 
| 5 | 
            +
            Feature:
         | 
| 6 | 
            +
             | 
| 7 | 
            +
            - use `Bundler.load_gemspec` instead of `eval`, to support Ruby 3.3
         | 
| 8 | 
            +
             | 
| 9 | 
            +
             | 
| 10 | 
            +
            ## v1.4.0 / 2021-01-18
         | 
| 11 | 
            +
             | 
| 12 | 
            +
            Feature:
         | 
| 13 | 
            +
             | 
| 14 | 
            +
            - Hoe::Markdown::Standalone allows additional non-gemspec files to be specified
         | 
| 15 | 
            +
             | 
| 16 | 
            +
             | 
| 3 17 | 
             
            ## v1.3.0 / 2020-08-28
         | 
| 4 18 |  | 
| 5 19 | 
             
            Feature:
         | 
    
        data/README.md
    CHANGED
    
    | @@ -98,7 +98,12 @@ require "hoe/markdown" | |
| 98 98 | 
             
            Hoe::Markdown::Standalone.new("gemname").define_markdown_tasks
         | 
| 99 99 | 
             
            ```
         | 
| 100 100 |  | 
| 101 | 
            -
            This will attempt to read your gemspec from `#{gemname}.gemspec`, and then the same rake tasks described above are created and behave the same way.
         | 
| 101 | 
            +
            This will attempt to read your gemspec from `#{gemname}.gemspec`, and then the same rake tasks described above are created and behave the same way. If you have additional files (beyond the files declared in the gemspec), you may pass them into this method:
         | 
| 102 | 
            +
             | 
| 103 | 
            +
            ``` ruby
         | 
| 104 | 
            +
            require "hoe/markdown"
         | 
| 105 | 
            +
            Hoe::Markdown::Standalone.new("gemname").define_markdown_tasks("CHANGELOG.md", "CONTRIBUTORS.md")
         | 
| 106 | 
            +
            ```
         | 
| 102 107 |  | 
| 103 108 |  | 
| 104 109 | 
             
            ## Contributing
         | 
    
        data/lib/hoe/markdown/util.rb
    CHANGED
    
    | @@ -27,6 +27,8 @@ class Hoe | |
| 27 27 | 
             
                    (?![[[:alnum:]]-])
         | 
| 28 28 | 
             
                  }x
         | 
| 29 29 |  | 
| 30 | 
            +
                  GIT_SHA1_REGEX = %{\b[0-9a-f]{5,40}\b}
         | 
| 31 | 
            +
             | 
| 30 32 | 
             
                  def self.linkify_github_issues(markdown, issues_uri)
         | 
| 31 33 | 
             
                    if issues_uri.nil? || issues_uri.empty?
         | 
| 32 34 | 
             
                      raise "#{__FILE__}:#{__method__}: URI for bugs cannot be empty\n"
         | 
| @@ -62,6 +64,10 @@ class Hoe | |
| 62 64 | 
             
                  def self.linkify_github_usernames(markdown)
         | 
| 63 65 | 
             
                    markdown.gsub(GITHUB_USER_REGEX, "[@\\1](https://github.com/\\1)")
         | 
| 64 66 | 
             
                  end
         | 
| 67 | 
            +
             | 
| 68 | 
            +
                  def self.linkify_git_commits(markdown)
         | 
| 69 | 
            +
                    markdown.gsub(GITHUB_SHA1_REGEX, "[`\\1`](https://)") # TODO YOU WERE HERE
         | 
| 70 | 
            +
                  end
         | 
| 65 71 | 
             
                end
         | 
| 66 72 | 
             
              end
         | 
| 67 73 | 
             
            end
         | 
    
        data/lib/hoe/markdown/version.rb
    CHANGED
    
    
    
        data/lib/hoe/markdown.rb
    CHANGED
    
    | @@ -25,8 +25,9 @@ class Hoe | |
| 25 25 | 
             
                  end
         | 
| 26 26 | 
             
                end
         | 
| 27 27 |  | 
| 28 | 
            -
                def define_markdown_tasks
         | 
| 28 | 
            +
                def define_markdown_tasks(*additional_files)
         | 
| 29 29 | 
             
                  @markdown_linkify_files ||= default_markdown_linkify_files
         | 
| 30 | 
            +
                  @markdown_linkify_files = @markdown_linkify_files.append(*additional_files).uniq
         | 
| 30 31 | 
             
                  return if markdown_linkify_files.empty?
         | 
| 31 32 |  | 
| 32 33 | 
             
                  namespace_name = "markdown:linkify"
         | 
    
        metadata
    CHANGED
    
    | @@ -1,14 +1,14 @@ | |
| 1 1 | 
             
            --- !ruby/object:Gem::Specification
         | 
| 2 2 | 
             
            name: hoe-markdown
         | 
| 3 3 | 
             
            version: !ruby/object:Gem::Version
         | 
| 4 | 
            -
              version: 1. | 
| 4 | 
            +
              version: 1.5.0
         | 
| 5 5 | 
             
            platform: ruby
         | 
| 6 6 | 
             
            authors:
         | 
| 7 7 | 
             
            - Mike Dalessio
         | 
| 8 8 | 
             
            autorequire: 
         | 
| 9 9 | 
             
            bindir: bin
         | 
| 10 10 | 
             
            cert_chain: []
         | 
| 11 | 
            -
            date:  | 
| 11 | 
            +
            date: 2023-10-10 00:00:00.000000000 Z
         | 
| 12 12 | 
             
            dependencies:
         | 
| 13 13 | 
             
            - !ruby/object:Gem::Dependency
         | 
| 14 14 | 
             
              name: rake
         | 
| @@ -32,6 +32,7 @@ executables: [] | |
| 32 32 | 
             
            extensions: []
         | 
| 33 33 | 
             
            extra_rdoc_files: []
         | 
| 34 34 | 
             
            files:
         | 
| 35 | 
            +
            - ".github/workflows/ci.yml"
         | 
| 35 36 | 
             
            - ".gitignore"
         | 
| 36 37 | 
             
            - ".rspec"
         | 
| 37 38 | 
             
            - ".travis.yml"
         | 
| @@ -68,7 +69,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement | |
| 68 69 | 
             
                - !ruby/object:Gem::Version
         | 
| 69 70 | 
             
                  version: '0'
         | 
| 70 71 | 
             
            requirements: []
         | 
| 71 | 
            -
            rubygems_version: 3. | 
| 72 | 
            +
            rubygems_version: 3.5.0.dev
         | 
| 72 73 | 
             
            signing_key: 
         | 
| 73 74 | 
             
            specification_version: 4
         | 
| 74 75 | 
             
            summary: Hoe plugin with helpers for markdown documentation files.
         |