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

Discover and load debug.gem even if it's not in Gemfile #448

Merged
merged 5 commits into from
Nov 18, 2022

Conversation

k0kubun
Copy link
Member

@k0kubun k0kubun commented Nov 18, 2022

This is what I wanted to do in the debug command, which is not possible in debug.gem. The most useful and unique feature of binding.irb is that you don't need to write that in Gemfile. This load_bundled_debug_gem implementation applies it to the debug command on binding.irb.

This is a bit hacky for sure, but you can always avoid its risks by just adding debug.gem to Gemfile. Thus I believe this is a superset in terms of supported use cases.

@k0kubun k0kubun requested a review from st0012 November 18, 2022 10:02
Copy link
Member

@st0012 st0012 left a comment

Choose a reason for hiding this comment

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

👍 great idea

lib/irb/cmd/debug.rb Show resolved Hide resolved
@k0kubun k0kubun merged commit ff8b6fe into ruby:master Nov 18, 2022
@k0kubun k0kubun deleted the debug-force-load branch November 18, 2022 18:03
matzbot pushed a commit to ruby/ruby that referenced this pull request Nov 18, 2022
(ruby/irb#448)

* Minor fixes on debug command

* Discover and load debug.gem even if it's not in Gemfile

* Eliminate else for rescue

* Discover the latest one from all gem paths
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants