elves / elvish

Powerful scripting language & versatile interactive shell
https://elv.sh/
BSD 2-Clause "Simplified" License
5.65k stars 299 forks source link

Bracketed paste doesn't work with ConEmu #1761

Open balthild opened 8 months ago

balthild commented 8 months ago

I'm using elvish with ConEmu, which will add [200~ and [201~ when pasting text into the terminal. However, elvish seems do not handle it properly, leaving the surrounding control sequences unremoved.

According to a contributor (issue link), elvish supports bracketed paste. I tried searching the docs, and find that there is only one option related to bracketed paste. However, it does not work for me (no any change after setting it to $true or $false).

I'm not sure if there are some error in my config. I also tried removing the config file and letting elvish to run with its default config. Still, it does not works.

Screenshots: (elvish, powershell, and WSL's bash):

图片

图片

图片

xiaq commented 8 months ago

The Windows build has a different input reader that doesn't handle VT input sequences at all, so the bracketed paste handling code is left out too. In light of the discussion in #1744 eventually I'll just use the same VT sequence-based input reader, but before that happens it'd make sense to graft the bracketed paste handling code to the Windows input reader too.