From b44e69a8f201a7176250ca441e9fcb2daf915af7 Mon Sep 17 00:00:00 2001 From: Kevin Locke Date: Sat, 10 Aug 2019 20:06:52 -0600 Subject: [PATCH] Delay evaluation by moving to after directory This plugin evaluates the modeline during the `autocmd BufRead` event, which occurs before the modeline would normally be evaluated and, more importantly, before `:filetype detect`. This causes a filetype set in a modeline (e.g. `// vim: set ft=foo :`) not to work in cases that filetype is set in `~/.vim/filetype.vim` or a `ftdetect` script from a package. This commit fixes the issue by moving the script to the package `after` directory which causes `autocmd BufRead` to be executed after `:filetype detect` as it would be if this plugin were not installed. Fixes: #20 Signed-off-by: Kevin Locke --- {plugin => after/plugin}/securemodelines.vim | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename {plugin => after/plugin}/securemodelines.vim (100%) diff --git a/plugin/securemodelines.vim b/after/plugin/securemodelines.vim similarity index 100% rename from plugin/securemodelines.vim rename to after/plugin/securemodelines.vim