*g:osc52_disable_paste*
If your terminal does not support pasting via OSC 52, or has it disabled, then
-it is a good idea to set g:osc52_disable_paste to TRUE. This will cause an
-empty string to be returned when Vim attempts to query the osc52.vim provider,
-instead of doing a blocking wait, as said in |osc52-support|.
+it is a good idea to set g:osc52_disable_paste to TRUE. This will register
+only the "copy" method for the osc52.vim clipboard provider, so Vim will not
+attempt an OSC 52 paste query and avoids the blocking wait described in
+|osc52-support|.
==============================================================================
vim:tw=78:ts=8:fo=tcq2:ft=help:
# Vim plugin for OSC52 clipboard support
#
# Maintainer: The Vim Project <https://github.com/vim/vim>
-# Last Change: 2025 Dec 18
+# Last Change: 2026 Mar 01
if !has("timers")
finish
import autoload "../autoload/osc52.vim" as osc
-v:clipproviders["osc52"] = {
+var provider: dict<any> = {
"available": osc.Available,
- "paste": {
- "*": osc.Paste,
- "+": osc.Paste
- },
"copy": {
"*": osc.Copy,
"+": osc.Copy
},
}
+if !get(g:, 'osc52_disable_paste', 0)
+ provider->extend({
+ "paste": {
+ "*": osc.Paste,
+ "+": osc.Paste
+ }
+ })
+endif
+
+v:clipproviders["osc52"] = provider
+
def SendDA1(): void
if !has("gui_running") && !get(g:, 'osc52_force_avail', 0)
&& !get(g:, 'osc52_no_da1', 0)