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 support for the case that RDoc is installed as a default gem #1

Merged

Conversation

kou
Copy link

@kou kou commented Oct 26, 2024

No description provided.

@kou kou force-pushed the add-rubygems-hook-default-gem branch from b61bc5d to e88ba9c Compare November 1, 2024 22:42

def self.generation_hook installer, specs; end
# Generate document for compatibility if this is a default gem.
RubyGemsHook.generation_hook(installer, specs)
Copy link
Owner

@mterada1228 mterada1228 Nov 6, 2024

Choose a reason for hiding this comment

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

RubyGemsHook class doesn't have the generation_hook method.
Should you call RubyGemsHook.generate?

Suggested change
RubyGemsHook.generation_hook(installer, specs)
::RDoc::RubyGemsHook.generate(installer, specs)

Copy link
Author

Choose a reason for hiding this comment

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

I've applied the suggested change but can we remove the ::RDoc:: part to simplify this code?

Copy link
Owner

Choose a reason for hiding this comment

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

I made mistake, sorry...
I think ::RDoc is unnecessary too.

Copy link
Author

Choose a reason for hiding this comment

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

Removed!

Copy link
Owner

@mterada1228 mterada1228 left a comment

Choose a reason for hiding this comment

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

@kou

Thank you for your proposal.
I left some comments.

Please check them.

Co-authored-by: mterada1228 <[email protected]>
@kou
Copy link
Author

kou commented Nov 6, 2024

@mterada1228 Thanks! You're right! All of them are applied.

lib/rdoc/rubygems_hook.rb Outdated Show resolved Hide resolved
Copy link
Owner

@mterada1228 mterada1228 left a comment

Choose a reason for hiding this comment

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

@mterada1228 mterada1228 merged commit ee289f4 into mterada1228:add-rubygems-hook Nov 7, 2024
26 checks passed
@kou kou deleted the add-rubygems-hook-default-gem branch November 8, 2024 01:56
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