Skip to content

Commit 1b15d78

Browse files
authored
Add project metadata to the gemspec (brianmario#1089)
As per https://guides.rubygems.org/specification-reference/#metadata, add metadata to the gemspec file. This'll allow people to more easily access the source code, raise issues and read the changelog. These bug_tracker_uri, changelog_uri, documentation_uri, homepage_uri and source_code_uri links will appear on the rubygems page at https://rubygems.org/gems/mysql2 and be available via the rubygems API after the next release.
1 parent 982dbdb commit 1b15d78

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

mysql2.gemspec

+7
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,13 @@ Mysql2::GEMSPEC = Gem::Specification.new do |s|
1010
s.homepage = 'https://github.com/brianmario/mysql2'
1111
s.rdoc_options = ["--charset=UTF-8"]
1212
s.summary = 'A simple, fast Mysql library for Ruby, binding to libmysql'
13+
s.metadata = {
14+
'bug_tracker_uri' => "#{s.homepage}/issues",
15+
'changelog_uri' => "#{s.homepage}/releases/tag/#{s.version}",
16+
'documentation_uri' => "https://www.rubydoc.info/gems/mysql2/#{s.version}",
17+
'homepage_uri' => s.homepage,
18+
'source_code_uri' => "#{s.homepage}/tree/#{s.version}",
19+
}
1320
s.required_ruby_version = '>= 2.0.0'
1421

1522
s.files = `git ls-files README.md CHANGELOG.md LICENSE ext lib support`.split

0 commit comments

Comments
 (0)