]> git.rmz.io Git - dotfiles.git/blobdiff - vimrc
show tabs and trailing spaces
[dotfiles.git] / vimrc
diff --git a/vimrc b/vimrc
index 53183df21e21a7fbf941c120a0015bab0d2bc73c..3170bb36ee1f42b7bfa4ff1a2cf813cae394ee07 100644 (file)
--- a/vimrc
+++ b/vimrc
@@ -95,8 +95,10 @@ if has("autocmd")
   " (happens when dropping a file on gvim).
   " Also don't do it when the mark is in the first line, that is the default
   " position when opening a file.
+  " blacklist certain filetype, you can get a file type with :echo &ft
+  let blacklist = ['gitcommit']
   autocmd BufReadPost *
-    \ if line("'\"") > 1 && line("'\"") <= line("$") |
+    \ if index(blacklist, &ft) < 0 && line("'\"") > 1 && line("'\"") <= line("$") |
     \   exe "normal! g`\"" |
     \ endif
 
@@ -140,6 +142,8 @@ set shiftwidth=4
 set expandtab
 
 set showbreak=▒▒
+" show these chars for tabs and trailing spaces
+set list listchars=tab:»·,trail:·
 
 set pastetoggle=<F11>
 " split right when using :vsp