webmention-cli 2.0.0 → 3.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: ffe5ed94ca3826e7bbde73673af684d2e5cf14bcd88923b3016d2c9f6f2b0621
4
- data.tar.gz: 614c66da93de19e0dbe0934c0729e45d16aac9b8c585d80d6449a1931dcbb6ed
3
+ metadata.gz: 83da64f93ee05a5d647d84a93c014f6e7bf4300c1db06fa7cf322dd0bcf87fe9
4
+ data.tar.gz: 597da96d89e4fb38a856d07fc6690fcb681c905fe32768ce0be8dfddc968c263
5
5
  SHA512:
6
- metadata.gz: 27d70232453c7b8694b48fd633875bf43854ede49ef35edf6cb5a7ba88b434baaaa53489548f2a6b8de460981d299b8d05378d15b5804ae64a51f68c1727443f
7
- data.tar.gz: 7bb36cf15f8954a40871905bca46899c5f4230fa4546797c45f5e255c040f3df1c4782b20a3dc2ff133456ecf5623f75c3cc63b57c16f96ea64ce638fe41cf89
6
+ metadata.gz: 3efe45c726bce67dffbac9c0d9dad64790d7b32ebc6d42cd818c5e90c8c9ade33504ebfacdf0ae7a3f07d486d58de8eccbc4c0b16e36042a26c07a2a513122e4
7
+ data.tar.gz: 88be3d7ae0cd17797fc13415b973ad587ced90de4e3a9fff46240a12239aa5e4fa30eeac30914f945ceef69ac653017ffc27c83257f90542b01e02fe0f052a7c
data/CHANGELOG.md CHANGED
@@ -1,5 +1,18 @@
1
1
  # Changelog
2
2
 
3
+ ## 3.0.1 / 2023-12-30
4
+
5
+ - Add `source_code_uri` to metadata (caf4022)
6
+
7
+ ## 3.0.0 / 2023-12-12
8
+
9
+ - **Breaking change:** Update Thor and Webmention dependencies (#90) (b89a756)
10
+ - Address RuboCop warnings (#89) (9a405bf)
11
+ - Code cleanup (#88) (445984f)
12
+ - **Breaking change:** Update Ruby versions (#87) (8a36cd3)
13
+ - Development: 2.7.8
14
+ - Minimum supported: 2.7
15
+
3
16
  ## 2.0.0 / 2022-05-20
4
17
 
5
18
  - **Breaking change:** Rewrite gem code (35e9442)
data/README.md CHANGED
@@ -4,20 +4,14 @@
4
4
 
5
5
  [![Gem](https://img.shields.io/gem/v/webmention-cli.svg?logo=rubygems&style=for-the-badge)](https://rubygems.org/gems/webmention-cli)
6
6
  [![Downloads](https://img.shields.io/gem/dt/webmention-cli.svg?logo=rubygems&style=for-the-badge)](https://rubygems.org/gems/webmention-cli)
7
- [![Build](https://img.shields.io/github/workflow/status/jgarber623/webmention-cli/CI?logo=github&style=for-the-badge)](https://github.com/jgarber623/webmention-cli/actions/workflows/ci.yml)
8
- [![Maintainability](https://img.shields.io/codeclimate/maintainability/jgarber623/webmention-cli.svg?logo=code-climate&style=for-the-badge)](https://codeclimate.com/github/jgarber623/webmention-cli)
9
- [![Coverage](https://img.shields.io/codeclimate/c/jgarber623/webmention-cli.svg?logo=code-climate&style=for-the-badge)](https://codeclimate.com/github/jgarber623/webmention-cli/code)
10
-
11
- ## Getting Started
12
-
13
- Before installing and using webmention-cli, you'll want to have [Ruby](https://www.ruby-lang.org) 2.6 (or newer) installed. It's recommended that you use a Ruby version managment tool like [rbenv](https://github.com/rbenv/rbenv), [chruby](https://github.com/postmodern/chruby), or [rvm](https://github.com/rvm/rvm).
14
-
15
- webmention-cli is developed using Ruby 2.6.10 and is additionally tested against Ruby 2.7, 3.0, and 3.1 using [GitHub Actions](https://github.com/jgarber623/webmention-cli/actions).
7
+ [![Build](https://img.shields.io/github/actions/workflow/status/jgarber623/webmention-cli/ci.yml?branch=main&logo=github&style=for-the-badge)](https://github.com/jgarber623/webmention-cli/actions/workflows/ci.yml)
16
8
 
17
9
  ## Installation
18
10
 
11
+ Before installing and using webmention-cli, you'll want to have [Ruby](https://www.ruby-lang.org) 2.7 (or newer) installed.
12
+
19
13
  ```sh
20
- gem install webmention-cli
14
+ $ gem install webmention-cli
21
15
  ```
22
16
 
23
17
  ## Usage
@@ -75,10 +69,6 @@ $ webmention verify https://kartikprabhu.com/notes/re-launching-franciscms https
75
69
 
76
70
  The command will return a zero exit code if `<source>` links to `<target>` _and_ the provided vouch URL links to the `<source>`'s domain. A non-zero exist code is returned in all other cases.
77
71
 
78
- ## Contributing
79
-
80
- Interested in helping improve webmention-cli? Awesome! Your help is greatly appreciated. See [CONTRIBUTING.md](https://github.com/jgarber623/webmention-cli/blob/main/CONTRIBUTING.md) for details.
81
-
82
72
  ## Acknowledgments
83
73
 
84
74
  webmention-cli wouldn't exist without Webmention and the hard work put in by everyone involved in the [IndieWeb](https://indieweb.org) movement.
data/exe/webmention CHANGED
@@ -1,9 +1,9 @@
1
1
  #!/usr/bin/env ruby
2
2
  # frozen_string_literal: true
3
3
 
4
- lib = File.expand_path('../lib', __dir__)
4
+ lib = File.expand_path("../lib", __dir__)
5
5
  $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
6
6
 
7
- require 'webmention/cli'
7
+ require "webmention/cli"
8
8
 
9
9
  Webmention::CLI::Runner.start
@@ -5,9 +5,9 @@ module Webmention
5
5
  class Runner < Thor
6
6
  include Thor::Actions
7
7
 
8
- package_name 'Webmention'
8
+ package_name "Webmention"
9
9
 
10
- map ['-v', '--version'] => :version
10
+ map ["-v", "--version"] => :version
11
11
 
12
12
  # :nocov:
13
13
  def self.exit_on_failure?
@@ -15,7 +15,7 @@ module Webmention
15
15
  end
16
16
  # :nocov:
17
17
 
18
- desc 'endpoint <target>', 'Discover the Webmention endpoint for <target> URL'
18
+ desc "endpoint <target>", "Discover the Webmention endpoint for <target> URL"
19
19
  def endpoint(target)
20
20
  url = Webmention::Url.new(target)
21
21
 
@@ -24,30 +24,30 @@ module Webmention
24
24
  say url.webmention_endpoint
25
25
  end
26
26
 
27
- desc 'send <source> <target>', 'Send a webmention from <source> URL to <target> URL'
28
- option :vouch, desc: 'Submit a <vouch> URL'
27
+ desc "send <source> <target>", "Send a webmention from <source> URL to <target> URL"
28
+ option :vouch, desc: "Submit a <vouch> URL"
29
29
  def send(source, target)
30
30
  response = Webmention.send_webmention(source, target, vouch: options[:vouch])
31
31
 
32
32
  exit 1 unless response.ok?
33
33
 
34
34
  code = response.code
35
- location = response.headers['Location']
35
+ location = response.headers["Location"]
36
36
 
37
37
  say(code == 201 && location ? location : "#{code} #{response.reason}")
38
38
 
39
39
  exit 1 unless code.between?(200, 299)
40
40
  end
41
41
 
42
- desc 'verify <source> <target>', 'Verify that <source> URL links to <target> URL'
43
- option :vouch, desc: 'Verify that <vouch> URL mentions the <source> URL domain'
42
+ desc "verify <source> <target>", "Verify that <source> URL links to <target> URL"
43
+ option :vouch, desc: "Verify that <vouch> URL mentions the <source> URL domain"
44
44
  def verify(source, target)
45
45
  verification = Webmention.verify_webmention(source, target, vouch: options[:vouch])
46
46
 
47
47
  exit 1 unless verification.verified?
48
48
  end
49
49
 
50
- desc 'version', 'Print version information'
50
+ desc "version", "Print version information"
51
51
  def version
52
52
  say "webmention-cli version #{Webmention::CLI::VERSION}"
53
53
  end
@@ -2,6 +2,6 @@
2
2
 
3
3
  module Webmention
4
4
  module CLI
5
- VERSION = '2.0.0'
5
+ VERSION = "3.0.1"
6
6
  end
7
7
  end
@@ -1,7 +1,8 @@
1
1
  # frozen_string_literal: true
2
2
 
3
- require 'thor'
4
- require 'webmention'
3
+ require "thor"
4
+ require "webmention"
5
5
 
6
- require_relative 'cli/version'
7
- require_relative 'cli/runner'
6
+ require_relative "cli/version"
7
+
8
+ require_relative "cli/runner"
@@ -1,34 +1,35 @@
1
1
  # frozen_string_literal: true
2
2
 
3
- require_relative 'lib/webmention/cli/version'
3
+ require_relative "lib/webmention/cli/version"
4
4
 
5
5
  Gem::Specification.new do |spec|
6
- spec.required_ruby_version = '>= 2.6', '< 4'
6
+ spec.required_ruby_version = ">= 2.7"
7
7
 
8
- spec.name = 'webmention-cli'
8
+ spec.name = "webmention-cli"
9
9
  spec.version = Webmention::CLI::VERSION
10
- spec.authors = ['Jason Garber']
11
- spec.email = ['jason@sixtwothree.org']
10
+ spec.authors = ["Jason Garber"]
11
+ spec.email = ["jason@sixtwothree.org"]
12
12
 
13
- spec.summary = 'A command-line interface for Webmention.'
13
+ spec.summary = "A command-line interface for Webmention."
14
14
  spec.description = spec.summary
15
- spec.homepage = 'https://github.com/jgarber623/webmention-cli'
16
- spec.license = 'MIT'
15
+ spec.homepage = "https://github.com/jgarber623/webmention-cli"
16
+ spec.license = "MIT"
17
17
 
18
- spec.files = Dir['lib/**/*'].reject { |f| File.directory?(f) }
19
- spec.files += %w[LICENSE CHANGELOG.md CONTRIBUTING.md README.md]
20
- spec.files += %w[webmention-cli.gemspec]
18
+ spec.files = Dir["lib/**/*"].reject { |f| File.directory?(f) }
19
+ spec.files += ["LICENSE", "CHANGELOG.md", "README.md"]
20
+ spec.files += ["webmention-cli.gemspec"]
21
21
 
22
- spec.bindir = 'exe'
23
- spec.executables = ['webmention']
24
- spec.require_paths = ['lib']
22
+ spec.bindir = "exe"
23
+ spec.executables = ["webmention"]
24
+ spec.require_paths = ["lib"]
25
25
 
26
26
  spec.metadata = {
27
- 'bug_tracker_uri' => "#{spec.homepage}/issues",
28
- 'changelog_uri' => "#{spec.homepage}/blob/v#{spec.version}/CHANGELOG.md",
29
- 'rubygems_mfa_required' => 'true'
27
+ "bug_tracker_uri" => "#{spec.homepage}/issues",
28
+ "changelog_uri" => "#{spec.homepage}/blob/v#{spec.version}/CHANGELOG.md",
29
+ "rubygems_mfa_required" => "true",
30
+ "source_code_uri" => "#{spec.homepage}/tree/v#{spec.version}"
30
31
  }
31
32
 
32
- spec.add_runtime_dependency 'thor', '~> 1.2'
33
- spec.add_runtime_dependency 'webmention', '~> 6.0'
33
+ spec.add_runtime_dependency "thor", "~> 1.3"
34
+ spec.add_runtime_dependency "webmention", "~> 7.0"
34
35
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: webmention-cli
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.0
4
+ version: 3.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jason Garber
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2022-05-21 00:00:00.000000000 Z
11
+ date: 2023-12-30 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: thor
@@ -16,28 +16,28 @@ dependencies:
16
16
  requirements:
17
17
  - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: '1.2'
19
+ version: '1.3'
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.2'
26
+ version: '1.3'
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: webmention
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
31
  - - "~>"
32
32
  - !ruby/object:Gem::Version
33
- version: '6.0'
33
+ version: '7.0'
34
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: '6.0'
40
+ version: '7.0'
41
41
  description: A command-line interface for Webmention.
42
42
  email:
43
43
  - jason@sixtwothree.org
@@ -47,7 +47,6 @@ extensions: []
47
47
  extra_rdoc_files: []
48
48
  files:
49
49
  - CHANGELOG.md
50
- - CONTRIBUTING.md
51
50
  - LICENSE
52
51
  - README.md
53
52
  - exe/webmention
@@ -60,8 +59,9 @@ licenses:
60
59
  - MIT
61
60
  metadata:
62
61
  bug_tracker_uri: https://github.com/jgarber623/webmention-cli/issues
63
- changelog_uri: https://github.com/jgarber623/webmention-cli/blob/v2.0.0/CHANGELOG.md
62
+ changelog_uri: https://github.com/jgarber623/webmention-cli/blob/v3.0.1/CHANGELOG.md
64
63
  rubygems_mfa_required: 'true'
64
+ source_code_uri: https://github.com/jgarber623/webmention-cli/tree/v3.0.1
65
65
  post_install_message:
66
66
  rdoc_options: []
67
67
  require_paths:
@@ -70,17 +70,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
70
70
  requirements:
71
71
  - - ">="
72
72
  - !ruby/object:Gem::Version
73
- version: '2.6'
74
- - - "<"
75
- - !ruby/object:Gem::Version
76
- version: '4'
73
+ version: '2.7'
77
74
  required_rubygems_version: !ruby/object:Gem::Requirement
78
75
  requirements:
79
76
  - - ">="
80
77
  - !ruby/object:Gem::Version
81
78
  version: '0'
82
79
  requirements: []
83
- rubygems_version: 3.3.12
80
+ rubygems_version: 3.1.6
84
81
  signing_key:
85
82
  specification_version: 4
86
83
  summary: A command-line interface for Webmention.
data/CONTRIBUTING.md DELETED
@@ -1,37 +0,0 @@
1
- # Contributing to webmention-cli
2
-
3
- There are a couple ways you can help improve webmention-cli:
4
-
5
- 1. Fix an existing [issue][issues] and submit a [pull request][pulls].
6
- 1. Review open [pull requests][pulls].
7
- 1. Report a new [issue][issues]. _Only do this after you've made sure the behavior or problem you're observing isn't already documented in an open issue._
8
-
9
- ## Getting Started
10
-
11
- webmention-cli is developed using Ruby 2.6.10 and is additionally tested against Ruby 2.7, 3.0, and 3.1 using [GitHub Actions](https://github.com/jgarber623/webmention-cli/actions).
12
-
13
- Before making changes to webmention-cli, you'll want to install Ruby 2.6.10. It's recommended that you use a Ruby version managment tool like [rbenv](https://github.com/rbenv/rbenv), [chruby](https://github.com/postmodern/chruby), or [rvm](https://github.com/rvm/rvm). Once you've installed Ruby 2.6.10 using your method of choice, install the project's gems by running:
14
-
15
- ```sh
16
- bundle install
17
- ```
18
-
19
- ## Making Changes
20
-
21
- 1. Fork and clone the project's repo.
22
- 1. Install development dependencies as outlined above.
23
- 1. Create a feature branch for the code changes you're looking to make: `git checkout -b my-new-feature`.
24
- 1. _Write some code!_
25
- 1. If your changes would benefit from testing, add the necessary tests and verify everything passes by running `bundle exec rspec`.
26
- 1. Commit your changes: `git commit -am 'Add some new feature or fix some issue'`. _(See [this excellent article](https://chris.beams.io/posts/git-commit/) for tips on writing useful Git commit messages.)_
27
- 1. Push the branch to your fork: `git push -u origin my-new-feature`.
28
- 1. Create a new [pull request][pulls] and we'll review your changes.
29
-
30
- ## Code Style
31
-
32
- Code formatting conventions are defined in the `.editorconfig` file which uses the [EditorConfig](http://editorconfig.org) syntax. There are [plugins for a variety of editors](http://editorconfig.org/#download) that utilize the settings in the `.editorconfig` file. We recommended you install the EditorConfig plugin for your editor of choice.
33
-
34
- Your bug fix or feature addition won't be rejected if it runs afoul of any (or all) of these guidelines, but following the guidelines will definitely make everyone's lives a little easier.
35
-
36
- [issues]: https://github.com/jgarber623/webmention-cli/issues
37
- [pulls]: https://github.com/jgarber623/webmention-cli/pulls