newline not honored in Reline.readline("\nMy Prompt: ")
Open
Nobody has claimed this yet.
- Dominant language
- Ruby
- Stars
- 311
- Forks
- 99
- Avg merge
- 6d 4h
- Merged PRs (30d)
- 1
Description
Description
When I start my prompt with "\n" I am expecting that character to start a new line not to be printed to the terminal as two characters "" and "n" in front of my prompt text
$ ruby temp.rb
\nMy Prompt: hello world
hello world
$ cat temp.rb
require 'reline'
answer = Reline.readline("\nMy Prompt: ")
puts answer
Ruby version 3.3.0
Terminal Emulator
iTerm2
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the temp.rb reproduction and inspect the Reline.readline entry point for how its prompt string is rendered. Run it in the reported terminal setup, then verify that a prompt beginning with "\n" appears on a new line while the returned answer remains unchanged.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- ruby
- Domain
- cli
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 48/100