aboutsummaryrefslogtreecommitdiff
path: root/vim
diff options
context:
space:
mode:
authorTom Ryder <tom@sanctum.geek.nz>2017-11-02 14:13:32 +1300
committerTom Ryder <tom@sanctum.geek.nz>2017-11-02 14:16:59 +1300
commit080a0802d95ce3d89a4cfd9dded76d11b3092e88 (patch)
tree23875e4158bd99a3258fdb93a10ffac830316b03 /vim
parentExpand comment header for bigfile.vim (diff)
downloaddotfiles-080a0802d95ce3d89a4cfd9dded76d11b3092e88.tar.gz
dotfiles-080a0802d95ce3d89a4cfd9dded76d11b3092e88.zip
Make bigfile size variable an option with default
This arranges for g:big_file_size only to set itself to 10 MiB if the variable is not already set, presumably by the user in their vimrc.
Diffstat (limited to 'vim')
-rw-r--r--vim/plugin/bigfile.vim6
1 files changed, 4 insertions, 2 deletions
diff --git a/vim/plugin/bigfile.vim b/vim/plugin/bigfile.vim
index d1d9ca61..7f28c539 100644
--- a/vim/plugin/bigfile.vim
+++ b/vim/plugin/bigfile.vim
@@ -8,8 +8,10 @@
"
if has('eval') && has('autocmd')
- " Threshold is 10 MiB
- let g:big_file_size = 10 * 1024 * 1024
+ " Default threshold is 10 MiB
+ if !exists('g:big_file_size')
+ let g:big_file_size = 10 * 1024 * 1024
+ endif
" Declare function for turning off slow options
function! s:BigFileMeasures()