aboutsummaryrefslogtreecommitdiff
path: root/vim
diff options
context:
space:
mode:
authorTom Ryder <tom@sanctum.geek.nz>2018-06-29 23:32:48 +1200
committerTom Ryder <tom@sanctum.geek.nz>2018-06-29 23:32:48 +1200
commit6dd6103a1b5599a335aa18a84b5619b9f166e6ae (patch)
tree0f28985e61a05efc45927af58b3fc50c34fc0d6e /vim
parentUse ftplugins for filetype mappings instead (diff)
downloaddotfiles-6dd6103a1b5599a335aa18a84b5619b9f166e6ae.tar.gz
dotfiles-6dd6103a1b5599a335aa18a84b5619b9f166e6ae.zip
Add g:no_plugin_maps checks for ftplugin maps.vim
Diffstat (limited to 'vim')
-rw-r--r--vim/after/ftplugin/diff/maps.vim5
-rw-r--r--vim/after/ftplugin/html/maps.vim5
-rw-r--r--vim/after/ftplugin/make/maps.vim5
-rw-r--r--vim/after/ftplugin/perl/maps.vim5
-rw-r--r--vim/after/ftplugin/php/maps.vim5
-rw-r--r--vim/after/ftplugin/sh/maps.vim5
-rw-r--r--vim/after/ftplugin/vim/maps.vim5
-rw-r--r--vim/after/ftplugin/zsh/maps.vim5
8 files changed, 40 insertions, 0 deletions
diff --git a/vim/after/ftplugin/diff/maps.vim b/vim/after/ftplugin/diff/maps.vim
index f4ef8fd6..9ef5ddbf 100644
--- a/vim/after/ftplugin/diff/maps.vim
+++ b/vim/after/ftplugin/diff/maps.vim
@@ -10,6 +10,11 @@ if exists('b:did_ftplugin_diff_maps')
finish
endif
+" Don't load if the user doesn't want ftplugin mappings
+if exists('g:no_plugin_maps') || exists('g:no_diff_maps')
+ finish
+endif
+
" Flag as loaded
let b:did_ftplugin_diff_maps = 1
let b:undo_ftplugin = b:undo_ftplugin
diff --git a/vim/after/ftplugin/html/maps.vim b/vim/after/ftplugin/html/maps.vim
index e355d0e6..a1d51f75 100644
--- a/vim/after/ftplugin/html/maps.vim
+++ b/vim/after/ftplugin/html/maps.vim
@@ -10,6 +10,11 @@ if exists('b:did_ftplugin_html_maps')
finish
endif
+" Don't load if the user doesn't want ftplugin mappings
+if exists('g:no_plugin_maps') || exists('g:no_html_maps')
+ finish
+endif
+
" Flag as loaded
let b:did_ftplugin_html_maps = 1
let b:undo_ftplugin = b:undo_ftplugin
diff --git a/vim/after/ftplugin/make/maps.vim b/vim/after/ftplugin/make/maps.vim
index bfe82891..1f9e2078 100644
--- a/vim/after/ftplugin/make/maps.vim
+++ b/vim/after/ftplugin/make/maps.vim
@@ -10,6 +10,11 @@ if exists('b:did_ftplugin_make_maps')
finish
endif
+" Don't load if the user doesn't want ftplugin mappings
+if exists('g:no_plugin_maps') || exists('g:no_make_maps')
+ finish
+endif
+
" Flag as loaded
let b:did_ftplugin_make_maps = 1
let b:undo_ftplugin = b:undo_ftplugin
diff --git a/vim/after/ftplugin/perl/maps.vim b/vim/after/ftplugin/perl/maps.vim
index fe5def10..2340ac19 100644
--- a/vim/after/ftplugin/perl/maps.vim
+++ b/vim/after/ftplugin/perl/maps.vim
@@ -10,6 +10,11 @@ if exists('b:did_ftplugin_perl_maps')
finish
endif
+" Don't load if the user doesn't want ftplugin mappings
+if exists('g:no_plugin_maps') || exists('g:no_perl_maps')
+ finish
+endif
+
" Flag as loaded
let b:did_ftplugin_perl_maps = 1
let b:undo_ftplugin = b:undo_ftplugin
diff --git a/vim/after/ftplugin/php/maps.vim b/vim/after/ftplugin/php/maps.vim
index 32cc8388..9ccfc586 100644
--- a/vim/after/ftplugin/php/maps.vim
+++ b/vim/after/ftplugin/php/maps.vim
@@ -10,6 +10,11 @@ if exists('b:did_ftplugin_php_maps')
finish
endif
+" Don't load if the user doesn't want ftplugin mappings
+if exists('g:no_plugin_maps') || exists('g:no_php_maps')
+ finish
+endif
+
" Flag as loaded
let b:did_ftplugin_php_maps = 1
let b:undo_ftplugin = b:undo_ftplugin
diff --git a/vim/after/ftplugin/sh/maps.vim b/vim/after/ftplugin/sh/maps.vim
index e93a84c4..19d9300c 100644
--- a/vim/after/ftplugin/sh/maps.vim
+++ b/vim/after/ftplugin/sh/maps.vim
@@ -10,6 +10,11 @@ if exists('b:did_ftplugin_sh_maps')
finish
endif
+" Don't load if the user doesn't want ftplugin mappings
+if exists('g:no_plugin_maps') || exists('g:no_sh_maps')
+ finish
+endif
+
" Flag as loaded
let b:did_ftplugin_sh_maps = 1
let b:undo_ftplugin = b:undo_ftplugin
diff --git a/vim/after/ftplugin/vim/maps.vim b/vim/after/ftplugin/vim/maps.vim
index 7f2a07a0..f527aeda 100644
--- a/vim/after/ftplugin/vim/maps.vim
+++ b/vim/after/ftplugin/vim/maps.vim
@@ -10,6 +10,11 @@ if exists('b:did_ftplugin_vim_maps')
finish
endif
+" Don't load if the user doesn't want ftplugin mappings
+if exists('g:no_plugin_maps') || exists('g:no_vim_maps')
+ finish
+endif
+
" Flag as loaded
let b:did_ftplugin_vim_maps = 1
let b:undo_ftplugin = b:undo_ftplugin
diff --git a/vim/after/ftplugin/zsh/maps.vim b/vim/after/ftplugin/zsh/maps.vim
index a670df46..1d0ec2cc 100644
--- a/vim/after/ftplugin/zsh/maps.vim
+++ b/vim/after/ftplugin/zsh/maps.vim
@@ -10,6 +10,11 @@ if exists('b:did_ftplugin_zsh_maps')
finish
endif
+" Don't load if the user doesn't want ftplugin mappings
+if exists('g:no_plugin_maps') || exists('g:no_zsh_maps')
+ finish
+endif
+
" Flag as loaded
let b:did_ftplugin_zsh_maps = 1
let b:undo_ftplugin = b:undo_ftplugin