aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTom Ryder <tom@sanctum.geek.nz>2018-08-16 23:09:42 +1200
committerTom Ryder <tom@sanctum.geek.nz>2018-08-16 23:09:42 +1200
commitfe72038470554ec63a1f4b7ab532584bd15a05b9 (patch)
tree214710af8f2d9d8b6507b9733863d2fcab8d04dc
parent596610205ba22cbf27f3f40c4a7133f859570239 (diff)
downloaddotfiles-fe72038470554ec63a1f4b7ab532584bd15a05b9.tar.gz
Spin equalalways_resized.vim into its own dist
-rw-r--r--.gitmodules3
m---------vim/bundle/equalalways_resized0
-rw-r--r--vim/plugin/equalalways_resized.vim27
3 files changed, 3 insertions, 27 deletions
diff --git a/.gitmodules b/.gitmodules
index 0cc8fb3f..7bc3a80a 100644
--- a/.gitmodules
+++ b/.gitmodules
@@ -17,6 +17,9 @@
[submodule "vim/bundle/digraph_search"]
path = vim/bundle/digraph_search
url = https://sanctum.geek.nz/code/vim-digraph-search.git
+[submodule "vim/bundle/equalalways_resized"]
+ path = vim/bundle/equalalways_resized
+ url = https://sanctum.geek.nz/code/vim-equalalways-resized.git
[submodule "vim/bundle/foldlevelstart_stdin"]
path = vim/bundle/foldlevelstart_stdin
url = https://sanctum.geek.nz/code/vim-foldlevelstart-stdin.git
diff --git a/vim/bundle/equalalways_resized b/vim/bundle/equalalways_resized
new file mode 160000
+Subproject 5a2d7c57a82a17a763f904d19ea4417696c772b
diff --git a/vim/plugin/equalalways_resized.vim b/vim/plugin/equalalways_resized.vim
deleted file mode 100644
index 8865f0af..00000000
--- a/vim/plugin/equalalways_resized.vim
+++ /dev/null
@@ -1,27 +0,0 @@
-"
-" equalalways_resized: If 'equalalways' is set, extend it to VimResized
-" events.
-"
-" Author: Tom Ryder <tom@sanctum.geek.nz>
-" License: Same as Vim itself
-"
-if exists('g:loaded_equalalways_resized') || &compatible
- finish
-endif
-if !has('autocmd') || !has('windows') || !exists('##VimResized')
- finish
-endif
-let g:loaded_equalalways_resized = 1
-
-" If 'equalalways' is set, rebalance the windows
-function! s:Rebalance() abort
- if &equalalways
- wincmd =
- endif
-endfunction
-
-" Add hook for VimResized event
-augroup equalalways_resized
- autocmd!
- autocmd VimResized * call s:Rebalance()
-augroup END