-
Notifications
You must be signed in to change notification settings - Fork 4.1k
Description
What version of Bun is running?
1.3.10+30e609e08
What platform is your computer?
Linux 6.18.13-arch1-1 x86_64 unknown
What steps can reproduce the bug?
Test case with terminal width = 83:
> .copy "a".repeat(83)
(Press Ctrl+Shift+p or whatever key combination your terminal uses to paste)
What is the expected behavior?
A single pasted line with soft wrapping.
What do you see instead?
Two copies of the pasted line.
Additional information
When pasting text that does not fit in the available terminal width, bun repl generates a number of duplicate lines equal to the amount of characters that do not fit in the available width, and only the last line contains all of the characters (soft wrapped as expected).
For example, if the available terminal width is 83 columns, and you paste a line containing 83 characters, bun repl will generate 2 copies of the pasted line. Please note that this takes into account the 2 characters of the bun repl ("> ").
This bug seems to be related to issue #27461