shorten

Mon, 22 May 2017 23:18:03 -0400

author
Meredith Howard <mhoward@roomag.org>
date
Mon, 22 May 2017 23:18:03 -0400
changeset 580
5a9e9be223f0
parent 579
0cb7adee16fe
child 581
dbe8e6709cd5

shorten

.vim/autoload/vimrc.vim file | annotate | diff | comparison | revisions
--- a/.vim/autoload/vimrc.vim
+++ b/.vim/autoload/vimrc.vim
@@ -1,25 +1,23 @@
 
-function! vimrc#AutoFmtToggle() abort
+func! vimrc#AutoFmtToggle() abort
   if &formatoptions =~ 'a'
-    setl fo-=a
-    echo '-a'
+    setl fo-=a | echo '-a'
   else
-    setl fo+=a
-    echo '+a'
+    setl fo+=a | echo '+a'
   endif
-endfunction
+endfunc
 
 " Make paths when writing, as necessary
-function! vimrc#MkNonExDir(file, buf) abort
+func! vimrc#MkNonExDir(file, buf) abort
   if empty(getbufvar(a:buf, '&buftype')) && a:file!~#'\v^\w+\:\/'
     let dir=fnamemodify(a:file, ':h')
     if !isdirectory(dir)
       call mkdir(dir, 'p')
     endif
   endif
-endfunction
+endfunc
 
-function! vimrc#VundleInstallAndBegin() abort
+func! vimrc#VundleInstallAndBegin() abort
   let l:vundle_readme = expand(g:on_windows
     \ ? '~/vimfiles/bundle/vundle/README.md'
     \ : '~/.vim/bundle/vundle/README.md')
@@ -48,4 +46,4 @@ function! vimrc#VundleInstallAndBegin() 
     set rtp+=~/.vim/bundle/vundle/
     call vundle#begin()
   endif
-endfunction
+endfunc

mercurial