From afd07302487b0a9138c0a6c6aa5de6b887a09576 Mon Sep 17 00:00:00 2001 From: w0rp Date: Tue, 14 Feb 2017 09:18:54 +0000 Subject: [PATCH] #274 Stop airline from doing anything if ALE doesn't load by using a different flag for loading with a very ugly name --- plugin/ale.vim | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/plugin/ale.vim b/plugin/ale.vim index b871807..45b0b90 100644 --- a/plugin/ale.vim +++ b/plugin/ale.vim @@ -4,11 +4,13 @@ " Sanity Checks -if exists('g:loaded_ale') +if exists('g:loaded_ale_dont_use_this_in_other_plugins_please') finish endif -let g:loaded_ale = 1 +" Set a special flag used only by this plugin for preventing doubly +" loading the script. +let g:loaded_ale_dont_use_this_in_other_plugins_please = 1 " A flag for detecting if the required features are set. if has('nvim') @@ -30,6 +32,9 @@ if !s:has_features finish endif +" Set this flag so that other plugins can use it, like airline. +let g:loaded_ale = 1 + " Set the TMPDIR environment variable if it is not set automatically. " This can automatically fix some environments. if has('unix') && empty($TMPDIR)