New answers tagged

1

One way to do it is just force the filetype: vim <(script | ...) -c 'set filetype=html' Or inside vim :set filetype=javascript (For example)


3

Just use :h map-<expr> instead of auto-commands. let FT_IGNORE_QUOTES = ['vim', 'markdown', 'help'] inoremap <expr>' index(FT_IGNORE_QUOTES, &ft) < 0 ? "''<left>" : "'" inoremap <expr>" index(FT_IGNORE_QUOTES, &ft) < 0 ? '""<left>' : '"'


Top 50 recent answers are included