diff options
author | w0rp <devw0rp@gmail.com> | 2023-09-16 23:25:39 +0100 |
---|---|---|
committer | w0rp <devw0rp@gmail.com> | 2023-09-16 23:25:39 +0100 |
commit | bd9fc580a1cda702e8aa3de0d06086468fdaf3f4 (patch) | |
tree | 76050b5ee39f943aee591cf16adc1a0d25878941 /ale_linters/haskell | |
parent | dca621b6755a47469c94ee8fd26f390e34804077 (diff) | |
download | ale-bd9fc580a1cda702e8aa3de0d06086468fdaf3f4.zip |
Close #4541 - Fix Haskell project root detection
We weren't joining and returning paths correctly for detecting project
roots for Haskell projects, and now we are.
Co-authored-by: Rodrigo Mesquita <rodrigo.m.mesquita@gmail.com>
Diffstat (limited to 'ale_linters/haskell')
-rw-r--r-- | ale_linters/haskell/hls.vim | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/ale_linters/haskell/hls.vim b/ale_linters/haskell/hls.vim index 7f9efc38..7f7f42e1 100644 --- a/ale_linters/haskell/hls.vim +++ b/ale_linters/haskell/hls.vim @@ -16,8 +16,9 @@ function! ale_linters#haskell#hls#FindRootFile(buffer) abort for l:path in ale#path#Upwards(expand('#' . a:buffer . ':p:h')) for l:root_file in l:serach_root_files - if filereadable(l:path . l:root_file) - return l:path + if filereadable(l:path . '/' . l:root_file) + " Add on / so fnamemodify(..., ':h') below keeps the path. + return l:path . '/' endif endfor endfor |