mirror of
https://github.com/dense-analysis/ale.git
synced 2026-10-12 08:00:14 +08:00
Fix bug with detection of the PLT
Previously, it did not detect the PLT inside the `_build` directory and would always default to the default PLT or the one from the `kerl` tool.
This commit is contained in:
1 parent
aae6d30b1e
commit
c675212ddd
1 file changed
+2
-2
@@ -15,10 +15,10 @@ endfunction
|
|||||||
function! ale_linters#erlang#dialyzer#FindPlt(buffer) abort
|
function! ale_linters#erlang#dialyzer#FindPlt(buffer) abort
|
||||||
let l:plt_file = ''
|
let l:plt_file = ''
|
||||||
let l:rebar3_profile = ale_linters#erlang#dialyzer#GetRebar3Profile(a:buffer)
|
let l:rebar3_profile = ale_linters#erlang#dialyzer#GetRebar3Profile(a:buffer)
|
||||||
let l:plt_file_directory = ale#path#FindNearestDirectory(a:buffer, '_build' . l:rebar3_profile)
|
let l:plt_file_directory = ale#path#FindNearestDirectory(a:buffer, '_build/' . l:rebar3_profile)
|
||||||
|
|
||||||
if !empty(l:plt_file_directory)
|
if !empty(l:plt_file_directory)
|
||||||
let l:plt_file = split(globpath(l:plt_file_directory, '/*_plt'), '\n')
|
let l:plt_file = globpath(l:plt_file_directory, '*_plt', 0, 1)
|
||||||
endif
|
endif
|
||||||
|
|
||||||
if !empty(l:plt_file)
|
if !empty(l:plt_file)
|
||||||
|
|||||||
Reference in new issue
Block a user