diff options
Diffstat (limited to 'ftplugin/Dockerfile.vim')
-rw-r--r-- | ftplugin/Dockerfile.vim | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/ftplugin/Dockerfile.vim b/ftplugin/Dockerfile.vim index 909739aa..977be845 100644 --- a/ftplugin/Dockerfile.vim +++ b/ftplugin/Dockerfile.vim @@ -2,6 +2,12 @@ if exists('g:polyglot_disabled') && index(g:polyglot_disabled, 'dockerfile') != finish endif +" Define comment string +setlocal commentstring=#\ %s + +" Enable automatic comment insertion +setlocal formatoptions+=cro + function! DockerfileReplaceInstruction(original, replacement) let syn = synIDtrans(synID(line("."), col(".") - 1, 0)) if syn != hlID("Comment") && syn != hlID("Constant") && strlen(getline(".")) == 0 |