]> Sergey Matveev's repositories - st.git/commitdiff
Disable bracked paste in reset
authorRoberto E. Vargas Caballero <k0ga@shike2.net>
Fri, 28 Nov 2025 15:31:59 +0000 (16:31 +0100)
committerHiltjo Posthuma <hiltjo@codemadness.org>
Tue, 2 Dec 2025 19:09:47 +0000 (20:09 +0100)
Sadly, there are too many programs today that enable this mode
and it is becoming very common to find the terminal adding
characters before and after in every of your pastes. A reset
should disable this mode.

st.c

diff --git a/st.c b/st.c
index 8e579910165a90575000551bd575aab7fd4a901e..e55e7b33a16e35aa48f890a26ea11fbca4c9405d 100644 (file)
--- a/st.c
+++ b/st.c
@@ -2358,6 +2358,7 @@ eschandle(uchar ascii)
                resettitle();
                xloadcols();
                xsetmode(0, MODE_HIDE);
+               xsetmode(0, MODE_BRCKTPASTE);
                break;
        case '=': /* DECPAM -- Application keypad */
                xsetmode(1, MODE_APPKEYPAD);