File tree Expand file tree Collapse file tree 2 files changed +18
-2
lines changed
Expand file tree Collapse file tree 2 files changed +18
-2
lines changed Original file line number Diff line number Diff line change 22
33## [ unreleased]
44
5+ - ** Potential breaking change:** use ` confdir ` instead of ` srcdir ` as base path
6+ for ` lua_ls_project_root ` .
7+
8+ Prior to this change, ` lua_ls_project_root ` was resolved relative to the directory
9+ containing source ` .rst ` files. Documentation, however, was saying that it's resolved
10+ relative to the directory with ` conf.py ` .
11+
12+ This is not an issue, because in most projects ` conf.py ` and source ` .rst ` files
13+ are located in the same directory. Still, I've decided to be consistent with
14+ other Sphinx extensions and use ` confdir ` instead of ` srcdir ` .
15+
16+ This is a breaking change, but I don't believe there are any projects that
17+ use separate ` confdir ` and ` srcdir ` (the only reason to do this is if you're
18+ hosting multiple documentation sites in the same repo.) For this reason,
19+ this change is released as a minor version change.
20+
521## [ 3.3.0]
622
723- Added an option to extend list options (like ` :exclude-members: ` ) without overriding
Original file line number Diff line number Diff line change @@ -172,7 +172,7 @@ def set_options(app: sphinx.application.Sphinx):
172172 config = app .config
173173
174174 project_root = _path (
175- "lua_ls_project_root" , config ["lua_ls_project_root" ] or "" , app .srcdir
175+ "lua_ls_project_root" , config ["lua_ls_project_root" ] or "" , app .confdir
176176 )
177177
178178 domain_config = LuaDomainConfig (project_root = project_root )
@@ -260,7 +260,7 @@ def set_options(app: sphinx.application.Sphinx):
260260 domain_config .apidoc_roots = _api_roots (
261261 "lua_ls_apidoc_roots" ,
262262 config ["lua_ls_apidoc_roots" ],
263- app .srcdir ,
263+ app .confdir ,
264264 domain_config .apidoc_max_depth ,
265265 domain_config .apidoc_default_options ,
266266 domain_config .apidoc_ignored_modules ,
You can’t perform that action at this time.
0 commit comments