Forcefully set noro for CodeCommCommenting window
authorSergey Matveev <stargrave@stargrave.org>
Wed, 27 May 2020 17:37:15 +0000 (20:37 +0300)
committerSergey Matveev <stargrave@stargrave.org>
Wed, 27 May 2020 17:37:17 +0000 (20:37 +0300)
Because git difftool can invoke vimdiff with forced read-only windows.

plugin/codecomm.vim

index e7d1a762ed2bd6daf2edf40fddb6d3e1f5435a06..9226b4239e57ad15f64cef2f2451e54feb8d997c 100644 (file)
@@ -51,7 +51,7 @@ function! s:CodeComm() range
         execute cmd
     endfor
     " Spawn a new small code commenting window nonbinded to file
-    new CodeCommCommenting
+    new +set\ noreadonly CodeCommCommenting
     setlocal noswapfile
     setlocal buftype=acwrite
     call append("^", ready)