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

requiring byebug takes over readline from the app #81

Closed
rcanand opened this issue Sep 23, 2014 · 5 comments
Closed

requiring byebug takes over readline from the app #81

rcanand opened this issue Sep 23, 2014 · 5 comments
Labels

Comments

@rcanand
Copy link

rcanand commented Sep 23, 2014

In a command line Ruby (2.1.2) app (on Mac OS X 10.9.4), I use readline to enable history for my interactive prompt. I use byebug for debugging my ruby app. Within my app, when I use the up arrow to retrieve history, it shows the last commands used on byebug a few days ago, but does not seem to be recording my command history. Here is the relevant code in the app:

require 'byebug'
runner.cmd = Readline.readline(prompt, true)

and here is a sample run:

./myapp
...
myprompt> mycmd
...
myprompt>
[up arrow]
myprompt> q // this is the last byebug command, not mine 
[up arrow]
myprompt> c // this is a previous byebug command, not mine

If I remove 'require byebug' from my code, I get the correct readline history.

@deivid-rodriguez
Copy link
Owner

I'm sorry for stealing your command history... :S

I'll try to reproduce and fix this as soon as possible.

Thanks for reporting this, @rcanand !

@rcanand
Copy link
Author

rcanand commented Sep 25, 2014

👍

@deivid-rodriguez
Copy link
Owner

@rcanand I've fixed your issue and released 3.5.0. Could you check that everything is working fine? Thanks!

@rcanand
Copy link
Author

rcanand commented Sep 29, 2014

Yes, I verified that the problem is gone with 3.5.0. Thanks!

@deivid-rodriguez
Copy link
Owner

You're welcome! 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants