Change behavour so that if there is no parent directory matching the pattern for a project then the current directory will be the project root
parent
4addd3e668
commit
320c2bcd10
|
|
@ -10,7 +10,8 @@ local function find_project_dir()
|
||||||
)
|
)
|
||||||
|
|
||||||
if #found == 0 then
|
if #found == 0 then
|
||||||
return vim.loop.os_homedir()
|
-- if there are no parent directories matching the project pattern then use current directory as project directory
|
||||||
|
return vim.fn.getcwd()
|
||||||
end
|
end
|
||||||
|
|
||||||
local project_dir = vim.fs.dirname(found[1])
|
local project_dir = vim.fs.dirname(found[1])
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue