Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add homepage & metadata to betterlint.gemspec #43

Merged
merged 1 commit into from
Jun 4, 2024

Conversation

pboling
Copy link
Contributor

@pboling pboling commented May 2, 2024

Metadata will help people on RubyGems.org, or other library indexers, to find the source code, issue tracker, CHANGELOG, etc

Metadata will help people on RubyGems.org, or other library indexers, to find the source code, issue tracker, CHANGELOG, etc

s.homepage = "https://github.com/Betterment/#{s.name}"
s.metadata["homepage_uri"] = s.homepage
s.metadata["source_code_uri"] = "#{s.homepage}/tree/v#{s.version}"
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Dynamically links directly to the tag of the release for the version in the version.rb, which for any release is the source of that specific release!

Set once and forget it!

s.homepage = "https://github.com/Betterment/#{s.name}"
s.metadata["homepage_uri"] = s.homepage
s.metadata["source_code_uri"] = "#{s.homepage}/tree/v#{s.version}"
s.metadata["changelog_uri"] = "#{s.homepage}/blob/v#{s.version}/CHANGELOG.md"
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This will result in a link to the CHANGELOG.md directly from Rubygems.org.

s.metadata["homepage_uri"] = s.homepage
s.metadata["source_code_uri"] = "#{s.homepage}/tree/v#{s.version}"
s.metadata["changelog_uri"] = "#{s.homepage}/blob/v#{s.version}/CHANGELOG.md"
s.metadata["bug_tracker_uri"] = "#{s.homepage}/issues"
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Will also be linked from rubygems.org!

s.metadata["source_code_uri"] = "#{s.homepage}/tree/v#{s.version}"
s.metadata["changelog_uri"] = "#{s.homepage}/blob/v#{s.version}/CHANGELOG.md"
s.metadata["bug_tracker_uri"] = "#{s.homepage}/issues"
s.metadata["documentation_uri"] = "https://www.rubydoc.info/gems/#{s.name}/#{s.version}"
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Dynamically link to the version of the documentation that is specific to a given release!

Copy link
Member

@smudge smudge left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

domain LGTM && platform LGTM - thanks for the contribution!

@smudge smudge merged commit 922e77e into Betterment:main Jun 4, 2024
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants