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

Use reline #615

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Use reline #615

wants to merge 1 commit into from

Conversation

@MSP-Greg
Copy link
Collaborator

MSP-Greg commented Dec 22, 2019

I used the following for test/support/reline.rb on MinGW master

# frozen_string_literal: true

require "reline"

unless STDOUT.tty? && STDIN.tty?
  Reline.send(:remove_const, 'IOGate') if Reline.const_defined?('IOGate')
  Reline.const_set('IOGate', Reline::GeneralIO)
  Reline.send(:core).config.instance_variable_set(:@test_mode, true)
  Reline.send(:core).config.reset
  Reline.input = $stdin
end

Tests passed except:

  1) Failure:
Byebug::FinishInsideAutoloadedFilesTest#test_finish_inside_autoloaded_files [C:/Greg/GitHub/gl/byebug/test/commands/finish_test.rb:173]:
Expected: 5

  Actual: 172

EDIT: code taken from:
https://github.com/ruby/ruby/blob/master/test/readline/helper.rb#L13-L20

@MSP-Greg
Copy link
Collaborator

MSP-Greg commented Dec 22, 2019

EDIT: Ruby 2.5, 2.6, & master are passing. Had to throw a few windows related fixes at it, not sure if all are needed.

Maybe I'm missing something, but it seems that RubyGems can install io-console 0.5.3, but Bundler cannot.

Reline's ruby version spec starts with 2.5.

See:

https://github.com/MSP-Greg/byebug/runs/360346338

@deivid-rodriguez
Copy link
Owner Author

Can you open a new PR with whatever changes are needed to get things passing instead of working in your fork? That way we can benefit from your work.

Thank you 💜

The current version of reline needs at least ruby 2.5, so we catch up
with that requirement.
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.

Readline options?
2 participants