aboutsummaryrefslogtreecommitdiff
path: root/runtime/ftplugin
diff options
context:
space:
mode:
authorChristian Clason <c.clason@uni-graz.at>2025-06-09 22:35:00 +0200
committerChristian Clason <ch.clason+github@icloud.com>2025-06-10 09:10:59 +0200
commit4387c26691c19f69be241f01f7d4a9dd6792f413 (patch)
tree34f1811c56144cd06aad7ad97dfe0dfbdd2ae249 /runtime/ftplugin
parentb7cb7fe51c5f5711e525e2fb19fb83976f6496fc (diff)
downloadrneovim-4387c26691c19f69be241f01f7d4a9dd6792f413.tar.gz
rneovim-4387c26691c19f69be241f01f7d4a9dd6792f413.tar.bz2
rneovim-4387c26691c19f69be241f01f7d4a9dd6792f413.zip
vim-patch:9e9fe66: runtime(postscr): set commentstring option in ftplugin
closes: vim/vim#17486 https://github.com/vim/vim/commit/9e9fe664371e8a8523ba30edb9c6f71610511acb Co-authored-by: Riley Bruins <ribru17@hotmail.com>
Diffstat (limited to 'runtime/ftplugin')
-rw-r--r--runtime/ftplugin/postscr.vim4
1 files changed, 3 insertions, 1 deletions
diff --git a/runtime/ftplugin/postscr.vim b/runtime/ftplugin/postscr.vim
index b4c5e06324..eb53b38f09 100644
--- a/runtime/ftplugin/postscr.vim
+++ b/runtime/ftplugin/postscr.vim
@@ -3,6 +3,7 @@
" Maintainer: Mike Williams <mrw@eandem.co.uk>
" Last Change: 24th April 2012
" 2024 Jan 14 by Vim Project (browsefilter)
+" 2025 Jun 08 by Riley Bruins <ribru17@gmail.com> ('commentstring')
" Only do this when not done yet for this buffer
if exists("b:did_ftplugin")
@@ -17,6 +18,7 @@ set cpo&vim
" PS comment formatting
setlocal comments=b:%
+setlocal commentstring=%\ %s
setlocal formatoptions-=t formatoptions+=rol
" Define patterns for the matchit macro
@@ -36,7 +38,7 @@ if (has("gui_win32") || has("gui_gtk")) && !exists("b:browsefilter")
endif
endif
-let b:undo_ftplugin = "setlocal comments< formatoptions<"
+let b:undo_ftplugin = "setlocal comments< commentstring< formatoptions<"
\ . "| unlet! b:browsefilter b:match_ignorecase b:match_words"
let &cpo = s:cpo_save