diff --git a/ftplugin/javascript.vim b/ftplugin/javascript.vim index c3f3f53..4df3e94 100644 --- a/ftplugin/javascript.vim +++ b/ftplugin/javascript.vim @@ -4,8 +4,7 @@ endif let b:did_ftplugin = 1 "Besides installing the js-beautify globally or in the -"formatters/ folder, cloning the repository as a vim bundle -"is supported as well. +"formatters/ folder, installing as a vim bundle is supported. let s:prgname = "js-beautify" let s:arguments = "-i" @@ -17,7 +16,7 @@ if executable(s:prgpath) let b:formatprg=s:prgpath." ".s:arguments else "Else look for js-beautify globally - "or in the formatters/folder + "or in the formatters/ folder call g:FindFormatter(s:prgname,s:arguments) endif diff --git a/plugin/autoformat.vim b/plugin/autoformat.vim index f2a0012..fbe89ce 100644 --- a/plugin/autoformat.vim +++ b/plugin/autoformat.vim @@ -13,7 +13,7 @@ function! s:Autoformat() endif endfunction -"Create a command for this +"Create a command for formatting the entire buffer command! Autoformat call s:Autoformat() "Function for finding and setting the formatter @@ -37,8 +37,3 @@ endfunction "So when buffer/window/tab changes, "(re)load formatprg from the bufferlocal variable au BufEnter,WinEnter * if exists("b:formatprg") | let &formatprg=b:formatprg - -let b:autoformat = 1 -if b:autoformat==1 - inoremap Vgqo -endif