aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--vim/after/ftplugin/sed.vim9
-rw-r--r--vim/ftplugin/sed.vim9
2 files changed, 9 insertions, 9 deletions
diff --git a/vim/after/ftplugin/sed.vim b/vim/after/ftplugin/sed.vim
deleted file mode 100644
index 56447a34..00000000
--- a/vim/after/ftplugin/sed.vim
+++ /dev/null
@@ -1,9 +0,0 @@
-" Extra configuration for sed scripts
-if &filetype !=# 'sed' || v:version < 700
- finish
-endif
-
-" Set comment formats
-setlocal comments=:#
-setlocal formatoptions+=or
-let b:undo_ftplugin .= '|setlocal comments< formatoptions<'
diff --git a/vim/ftplugin/sed.vim b/vim/ftplugin/sed.vim
new file mode 100644
index 00000000..350bc976
--- /dev/null
+++ b/vim/ftplugin/sed.vim
@@ -0,0 +1,9 @@
+" Only do this when not yet done for this buffer
+if exists('b:did_ftplugin')
+ finish
+endif
+
+" Set comment formats
+setlocal comments=:#
+setlocal formatoptions+=or
+let b:undo_ftplugin = 'setlocal comments< formatoptions<'