3 ms·
I have seen a ‘good terminal’, apparently. Can you name one?
by tinus_hn 6y ago
I have seen a ‘good terminal’, apparently. Can you name one?
- andrey_utkin 6y agoXfce4-terminal prompts for confirmation when there's newline in the pasted contents.
- JdeBP 6y agoTwo examples: PuTTY and Windows Terminal both present confirmation dialogue boxes before pasting multiline content.
- bombcar 6y agoiTerm seems to do this also at least with multi line pastes - and then zsh seems to wait for you to hit enter AGAIN before executing anything.
- CGamesPlay 6y agoIn iTerm, Edit -> Paste Special -> Warn Before Multi-Line Paste will disable it if you don't like it. It's probably better to disable it in zsh, but I don't know how to do that. iTerm also provides the "only pop up this warning when I'm at a shell prompt", which is ironically exactly when I don't want it to pop up (since zsh/fish detect it themselves).
- JNRowe 6y agoUsing "unset zle_bracketed_paste" should do what you want, but I've only tried it in rxvt-unicode and the vte-based term I have. It stops zsh reacting to the escape sequences used by multi-line paste, see the docs for a full explanation¹. If you were to use I'd recommend sticking it behind a "if $TERM" guard so that it you don't end up surprised if you switch to a term that doesn't warn at some point ;) ¹ http://zsh.sourceforge.net/Doc/Release/Parameters.html#index-bracketed-paste http://zsh.sourceforge.net/Doc/Release/Parameters.html#index...
- GoblinSlayer 6y agoPuTTY accepts multiline pastes for me just fine, I use it with nano.
- klyrs 6y agoI was musing over IPython's behavior right before reading your comment... it's not a terminal, per se, but if you paste in multiple lines, the input switches into a multiline mode. This suggests that bash could handle it in the same manner without relying on a terminal application. In my experience, the advice "don't paste garbage into your terminal" is about as useful as "don't make mistakes." Sometimes it happens when I forget to hit shift on copying from a terminal, or accidentally holding it while copying from another window. Humans make mistakes. I like seatbelts even though they've never saved my life.