On Mon, Jul 22, 2024 at 17:08:15 +0200, Thomas Schmitt wrote:
Since an upgrade from Debian 11 to 12 the vim command
:set mouse=
does not disable the "GUI" interpretation of pasting text or numbers
when vim is in normal mode [...]
I'm not sure how you've got it configured, but just having a ~/.vimrc
file should be enough to disable the default system vimrc which has all
that broken mouse crap.
Unless I've got another file somewhere that I've forgotten...?
Since an upgrade from Debian 11 to 12 the vim command
:set mouse=
does not disable the "GUI" interpretation of pasting text or numbers
when vim is in normal mode [...]
I'm not sure how you've got it configured, but just having a ~/.vimrc
file should be enough to disable the default system vimrc which has all
that broken mouse crap.
Not sure if related to the issue OP is having is the same but I had to
add this to my ~/.vimrc:
set mouse=v
https://unix.stackexchange.com/questions/139578/copy-paste-for-vim-is-not-working-when-mouse-set-mouse-a-is-on
On Mon, Jul 22, 2024 at 11:20 AM Greg Wooledge <greg@wooledge.org> wrote:
On Mon, Jul 22, 2024 at 17:08:15 +0200, Thomas Schmitt wrote:
Since an upgrade from Debian 11 to 12 the vim command
:set mouse=
does not disable the "GUI" interpretation of pasting text or numbers
when vim is in normal mode [...]
I'm not sure how you've got it configured, but just having a ~/.vimrc
file should be enough to disable the default system vimrc which has all that broken mouse crap.
Unless I've got another file somewhere that I've forgotten...?
Not sure if related to the issue OP is having is the same but I had to
add this to my ~/.vimrc:
set mouse=v
More discussion about the mouse setting here: https://unix.stackexchange.com/questions/139578/copy-paste-for-vim-is-not-working-when-mouse-set-mouse-a-is-on
In my testing, I ran vim with no arguments, and typed in a single line
of gibberish. Then, I moved the cursor to column 0. Finally, I typed
out the command 20l in a different terminal, highlighted it, and pasted
it into vim. Rather than moving my cursor 20 characters to the right,
it inserted the literal string "20l". Specifically, it acts as if I
had pressed "i20lESC". I began and ended in command mode, but command
text was inserted as if I had been in insert mode.
I found a fix: https://vi.stackexchange.com/questions/18001/why-cant-i-paste-commands-into-vi
Apparently when in an "xterm environment" (whatever that means; apparently
it includes rxvt-unicode), turning on bracketed paste mode works:
:set t_BE=
The = is required.
I would consider some convenient key mapping that should be executed before pasting line number instead of disabling bracketed paste completely. There
is a chance to paste something weird with hidden text from a web page or
from a HTML mail message.
Sysop: | Keyop |
---|---|
Location: | Huddersfield, West Yorkshire, UK |
Users: | 546 |
Nodes: | 16 (2 / 14) |
Uptime: | 151:21:40 |
Calls: | 10,383 |
Files: | 14,054 |
Messages: | 6,417,800 |