diff options
author | Adam Stankiewicz <sheerun@sher.pl> | 2020-10-25 03:19:58 +0100 |
---|---|---|
committer | Adam Stankiewicz <sheerun@sher.pl> | 2020-10-25 03:19:58 +0100 |
commit | cbde2571d4f79770ac552fe75440de72893bc73a (patch) | |
tree | c6bf43ecbf9ed76071713dc4cba028d32695987a /autoload/vital | |
parent | d73c4d156279bfbc2ea9fafcbacca5fc2bd6cfd1 (diff) | |
download | vim-polyglot-cbde2571d4f79770ac552fe75440de72893bc73a.tar.gz vim-polyglot-cbde2571d4f79770ac552fe75440de72893bc73a.zip |
Respect symlinks for resolving vim-polyglot as fallback, closes #605
Diffstat (limited to 'autoload/vital')
-rw-r--r-- | autoload/vital/_crystal.vim | 9 | ||||
-rw-r--r-- | autoload/vital/_crystal/ColorEcho.vim | 9 | ||||
-rw-r--r-- | autoload/vital/_crystal/Data/List.vim | 9 | ||||
-rw-r--r-- | autoload/vital/_crystal/Data/String.vim | 9 | ||||
-rw-r--r-- | autoload/vital/_crystal/Process.vim | 9 | ||||
-rw-r--r-- | autoload/vital/_crystal/Web/JSON.vim | 9 | ||||
-rw-r--r-- | autoload/vital/crystal.vim | 9 | ||||
-rw-r--r-- | autoload/vital/crystal.vital | 4 |
8 files changed, 7 insertions, 60 deletions
diff --git a/autoload/vital/_crystal.vim b/autoload/vital/_crystal.vim index b8ac5d32..b328af90 100644 --- a/autoload/vital/_crystal.vim +++ b/autoload/vital/_crystal.vim @@ -1,11 +1,6 @@ -let s:base = expand("<sfile>:h:h") -let Filter = { _, v -> stridx(v, s:base) == -1 && stridx(v, $VIMRUNTIME) == -1 && v !~ "after" } -let files = filter(globpath(&rtp, 'autoload/vital/_crystal.vim', 1, 1), Filter) -if len(files) > 0 - exec 'source ' . files[0] +if !polyglot#util#IsEnabled('crystal', expand('<sfile>:p')) finish endif -if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'crystal') == -1 let s:_plugin_name = expand('<sfile>:t:r') @@ -16,5 +11,3 @@ endfunction function! vital#{s:_plugin_name}#function(funcname) abort silent! return function(a:funcname) endfunction - -endif diff --git a/autoload/vital/_crystal/ColorEcho.vim b/autoload/vital/_crystal/ColorEcho.vim index 59c0ec88..7180dce6 100644 --- a/autoload/vital/_crystal/ColorEcho.vim +++ b/autoload/vital/_crystal/ColorEcho.vim @@ -1,11 +1,6 @@ -let s:base = expand("<sfile>:h:h") -let Filter = { _, v -> stridx(v, s:base) == -1 && stridx(v, $VIMRUNTIME) == -1 && v !~ "after" } -let files = filter(globpath(&rtp, 'autoload/vital/_crystal/ColorEcho.vim', 1, 1), Filter) -if len(files) > 0 - exec 'source ' . files[0] +if !polyglot#util#IsEnabled('crystal', expand('<sfile>:p')) finish endif -if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'crystal') == -1 " ___vital___ " NOTE: lines between '" ___vital___' is generated by :Vitalize. @@ -189,5 +184,3 @@ function! s:echo(str) abort let echorizer = s:get_echorizer(a:str) call echorizer.echo() endfunction - -endif diff --git a/autoload/vital/_crystal/Data/List.vim b/autoload/vital/_crystal/Data/List.vim index b2045a2a..68f87490 100644 --- a/autoload/vital/_crystal/Data/List.vim +++ b/autoload/vital/_crystal/Data/List.vim @@ -1,11 +1,6 @@ -let s:base = expand("<sfile>:h:h") -let Filter = { _, v -> stridx(v, s:base) == -1 && stridx(v, $VIMRUNTIME) == -1 && v !~ "after" } -let files = filter(globpath(&rtp, 'autoload/vital/_crystal/Data/List.vim', 1, 1), Filter) -if len(files) > 0 - exec 'source ' . files[0] +if !polyglot#util#IsEnabled('crystal', expand('<sfile>:p')) finish endif -if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'crystal') == -1 " ___vital___ " NOTE: lines between '" ___vital___' is generated by :Vitalize. @@ -465,5 +460,3 @@ function! s:combinations(list, r) abort endfunction " vim:set et ts=2 sts=2 sw=2 tw=0: - -endif diff --git a/autoload/vital/_crystal/Data/String.vim b/autoload/vital/_crystal/Data/String.vim index 8f6ddf3e..67cd217c 100644 --- a/autoload/vital/_crystal/Data/String.vim +++ b/autoload/vital/_crystal/Data/String.vim @@ -1,11 +1,6 @@ -let s:base = expand("<sfile>:h:h") -let Filter = { _, v -> stridx(v, s:base) == -1 && stridx(v, $VIMRUNTIME) == -1 && v !~ "after" } -let files = filter(globpath(&rtp, 'autoload/vital/_crystal/Data/String.vim', 1, 1), Filter) -if len(files) > 0 - exec 'source ' . files[0] +if !polyglot#util#IsEnabled('crystal', expand('<sfile>:p')) finish endif -if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'crystal') == -1 " ___vital___ " NOTE: lines between '" ___vital___' is generated by :Vitalize. @@ -629,5 +624,3 @@ function! s:split_posix_text(text, ...) abort endfunction " vim:set et ts=2 sts=2 sw=2 tw=0: - -endif diff --git a/autoload/vital/_crystal/Process.vim b/autoload/vital/_crystal/Process.vim index 315a4343..2da1a016 100644 --- a/autoload/vital/_crystal/Process.vim +++ b/autoload/vital/_crystal/Process.vim @@ -1,11 +1,6 @@ -let s:base = expand("<sfile>:h:h") -let Filter = { _, v -> stridx(v, s:base) == -1 && stridx(v, $VIMRUNTIME) == -1 && v !~ "after" } -let files = filter(globpath(&rtp, 'autoload/vital/_crystal/Process.vim', 1, 1), Filter) -if len(files) > 0 - exec 'source ' . files[0] +if !polyglot#util#IsEnabled('crystal', expand('<sfile>:p')) finish endif -if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'crystal') == -1 " ___vital___ " NOTE: lines between '" ___vital___' is generated by :Vitalize. @@ -174,5 +169,3 @@ endif " vim:set et ts=2 sts=2 sw=2 tw=0: - -endif diff --git a/autoload/vital/_crystal/Web/JSON.vim b/autoload/vital/_crystal/Web/JSON.vim index c17269cf..a1d01238 100644 --- a/autoload/vital/_crystal/Web/JSON.vim +++ b/autoload/vital/_crystal/Web/JSON.vim @@ -1,11 +1,6 @@ -let s:base = expand("<sfile>:h:h") -let Filter = { _, v -> stridx(v, s:base) == -1 && stridx(v, $VIMRUNTIME) == -1 && v !~ "after" } -let files = filter(globpath(&rtp, 'autoload/vital/_crystal/Web/JSON.vim', 1, 1), Filter) -if len(files) > 0 - exec 'source ' . files[0] +if !polyglot#util#IsEnabled('crystal', expand('<sfile>:p')) finish endif -if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'crystal') == -1 " ___vital___ " NOTE: lines between '" ___vital___' is generated by :Vitalize. @@ -180,5 +175,3 @@ endfunction " @vimlint(EVL102, 0, l:ns) " vim:set et ts=2 sts=2 sw=2 tw=0: - -endif diff --git a/autoload/vital/crystal.vim b/autoload/vital/crystal.vim index 7674c4ef..68938d83 100644 --- a/autoload/vital/crystal.vim +++ b/autoload/vital/crystal.vim @@ -1,11 +1,6 @@ -let s:base = expand("<sfile>:h:h") -let Filter = { _, v -> stridx(v, s:base) == -1 && stridx(v, $VIMRUNTIME) == -1 && v !~ "after" } -let files = filter(globpath(&rtp, 'autoload/vital/crystal.vim', 1, 1), Filter) -if len(files) > 0 - exec 'source ' . files[0] +if !polyglot#util#IsEnabled('crystal', expand('<sfile>:p')) finish endif -if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'crystal') == -1 let s:plugin_name = expand('<sfile>:t:r') let s:vital_base_dir = expand('<sfile>:h') @@ -335,5 +330,3 @@ else return a:list endfunction endif - -endif diff --git a/autoload/vital/crystal.vital b/autoload/vital/crystal.vital index 4a13eb01..0ad94eb5 100644 --- a/autoload/vital/crystal.vital +++ b/autoload/vital/crystal.vital @@ -1,10 +1,6 @@ -if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'crystal') == -1 - crystal bee84ae23effb0510137ad177e98c94d8b3657a6 Process Web.JSON ColorEcho - -endif |