aboutsummaryrefslogtreecommitdiff
path: root/vim
diff options
context:
space:
mode:
authorTom Ryder <tom@sanctum.geek.nz>2018-07-18 22:20:42 +1200
committerTom Ryder <tom@sanctum.geek.nz>2018-07-18 22:20:42 +1200
commitc840bdc71db0fb89cf5f20e353d3356c205e5b03 (patch)
treecf8e68a29b4177f8584e8f40c019ee8be44d2111 /vim
parentSet UTF-8 default 'encoding' (diff)
downloaddotfiles-c840bdc71db0fb89cf5f20e353d3356c205e5b03.tar.gz
dotfiles-c840bdc71db0fb89cf5f20e353d3356c205e5b03.zip
Make /usr/include 'path' setting hinge on +unix
Diffstat (limited to 'vim')
-rw-r--r--vim/after/ftplugin/c.vim9
-rw-r--r--vim/after/ftplugin/cpp.vim9
2 files changed, 14 insertions, 4 deletions
diff --git a/vim/after/ftplugin/c.vim b/vim/after/ftplugin/c.vim
index e101b20c..fff9de04 100644
--- a/vim/after/ftplugin/c.vim
+++ b/vim/after/ftplugin/c.vim
@@ -5,5 +5,10 @@ endif
" Set comment formats
setlocal include=^\\s*#\\s*include
-setlocal path+=/usr/include
-let b:undo_ftplugin .= '|setlocal include< path<'
+let b:undo_ftplugin .= '|setlocal include<'
+
+" Include headers on UNIX
+if has('unix')
+ setlocal path+=/usr/include
+ let b:undo_ftplugin .= '|setlocal path<'
+endif
diff --git a/vim/after/ftplugin/cpp.vim b/vim/after/ftplugin/cpp.vim
index a826bf43..38c94330 100644
--- a/vim/after/ftplugin/cpp.vim
+++ b/vim/after/ftplugin/cpp.vim
@@ -5,5 +5,10 @@ endif
" Set comment formats
setlocal include=^\\s*#\\s*include
-setlocal path+=/usr/include
-let b:undo_ftplugin .= '|setlocal include< path<'
+let b:undo_ftplugin .= '|setlocal include<'
+
+" Include headers on UNIX
+if has('unix')
+ setlocal path+=/usr/include
+ let b:undo_ftplugin .= '|setlocal path<'
+endif