sphinx-lua-ls 2.0.1__tar.gz → 3.1.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (191) hide show
  1. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/.github/workflows/ci.yaml +9 -3
  2. sphinx_lua_ls-3.1.0/CHANGELOG.md +148 -0
  3. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/CONTRIBUTING.md +10 -0
  4. {sphinx_lua_ls-2.0.1/sphinx_lua_ls.egg-info → sphinx_lua_ls-3.1.0}/PKG-INFO +5 -25
  5. sphinx_lua_ls-3.1.0/docs/example/.emmyrc.json +20 -0
  6. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/docs/example/logging.lua +17 -32
  7. sphinx_lua_ls-3.1.0/docs/source/apidoc.rst +79 -0
  8. sphinx_lua_ls-3.1.0/docs/source/autodoc.rst +466 -0
  9. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/docs/source/conf.py +11 -3
  10. sphinx_lua_ls-3.1.0/docs/source/directives.rst +395 -0
  11. sphinx_lua_ls-3.1.0/docs/source/example.rst +45 -0
  12. sphinx_lua_ls-3.1.0/docs/source/index.rst +30 -0
  13. sphinx_lua_ls-3.1.0/docs/source/installation.rst +187 -0
  14. sphinx_lua_ls-3.1.0/docs/source/quickstart.rst +267 -0
  15. sphinx_lua_ls-3.1.0/docs/source/roles.rst +58 -0
  16. sphinx_lua_ls-3.1.0/docs/source/settings.rst +202 -0
  17. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/pyproject.toml +5 -4
  18. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/sphinx_lua_ls/__init__.py +155 -18
  19. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/sphinx_lua_ls/_version.py +16 -3
  20. sphinx_lua_ls-3.1.0/sphinx_lua_ls/apidoc.py +296 -0
  21. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/sphinx_lua_ls/autodoc.py +380 -79
  22. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/sphinx_lua_ls/autoindex.py +34 -17
  23. sphinx_lua_ls-3.1.0/sphinx_lua_ls/domain.py +1396 -0
  24. sphinx_lua_ls-3.1.0/sphinx_lua_ls/inherited.py +150 -0
  25. sphinx_lua_ls-3.1.0/sphinx_lua_ls/intersphinx.py +268 -0
  26. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/sphinx_lua_ls/lua_ls.py +293 -105
  27. sphinx_lua_ls-3.1.0/sphinx_lua_ls/objtree.py +1148 -0
  28. sphinx_lua_ls-3.1.0/sphinx_lua_ls/pygments.py +21 -0
  29. sphinx_lua_ls-3.1.0/sphinx_lua_ls/utils.py +370 -0
  30. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0/sphinx_lua_ls.egg-info}/PKG-INFO +5 -25
  31. sphinx_lua_ls-3.1.0/sphinx_lua_ls.egg-info/SOURCES.txt +176 -0
  32. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/sphinx_lua_ls.egg-info/requires.txt +2 -0
  33. sphinx_lua_ls-3.1.0/test/roots/test-apidoc/.gitignore +1 -0
  34. sphinx_lua_ls-3.1.0/test/roots/test-apidoc/conf.py +13 -0
  35. sphinx_lua_ls-3.1.0/test/roots/test-apidoc/index.rst +6 -0
  36. sphinx_lua_ls-3.1.0/test/roots/test-apidoc/lua/mod/inner.lua +14 -0
  37. sphinx_lua_ls-3.1.0/test/roots/test-apidoc/lua/mod.lua +21 -0
  38. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/test/roots/test-autodoc/conf.py +2 -0
  39. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/test/roots/test-autodoc/index.rst +1 -0
  40. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/test/roots/test-autodoc/lua/annotations.lua +1 -1
  41. sphinx_lua_ls-3.1.0/test/roots/test-autodoc/lua/globals.lua +16 -0
  42. sphinx_lua_ls-3.1.0/test/roots/test-autodoc/lua/globals_2.lua +13 -0
  43. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/test/roots/test-autodoc/lua/member_ordering.lua +1 -1
  44. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/test/roots/test-autodoc/lua/module_title.lua +1 -1
  45. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/test/roots/test-autodoc/lua/nested_modules.lua +1 -1
  46. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/test/roots/test-autodoc/lua/nesting.lua +1 -1
  47. sphinx_lua_ls-3.1.0/test/roots/test-autodoc/lua/object_types.lua +139 -0
  48. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/test/roots/test-autodoc/lua/relative_resolve.lua +1 -1
  49. sphinx_lua_ls-3.1.0/test/roots/test-autodoc/src/annotations.rst +26 -0
  50. sphinx_lua_ls-3.1.0/test/roots/test-autodoc/src/autoindex.rst +12 -0
  51. sphinx_lua_ls-3.1.0/test/roots/test-autodoc/src/globals.rst +9 -0
  52. sphinx_lua_ls-3.1.0/test/roots/test-autodoc/src/member_ordering.rst +40 -0
  53. sphinx_lua_ls-3.1.0/test/roots/test-autodoc/src/module_title.rst +28 -0
  54. sphinx_lua_ls-3.1.0/test/roots/test-autodoc/src/nested_modules.rst +8 -0
  55. sphinx_lua_ls-3.1.0/test/roots/test-autodoc/src/nesting.rst +77 -0
  56. sphinx_lua_ls-3.1.0/test/roots/test-autodoc/src/nesting_recursive.rst +78 -0
  57. sphinx_lua_ls-3.1.0/test/roots/test-autodoc/src/object_types.rst +8 -0
  58. sphinx_lua_ls-3.1.0/test/roots/test-autodoc/src/relative_resolve.rst +6 -0
  59. {sphinx_lua_ls-2.0.1/test/roots/test-autodoc-roots → sphinx_lua_ls-3.1.0/test/roots/test-autodoc-emmylua}/conf.py +2 -0
  60. sphinx_lua_ls-3.1.0/test/roots/test-autodoc-emmylua/index.rst +20 -0
  61. sphinx_lua_ls-3.1.0/test/roots/test-autodoc-emmylua/lua/.emmyrc.json +94 -0
  62. sphinx_lua_ls-3.1.0/test/roots/test-autodoc-emmylua/lua/annotations.lua +44 -0
  63. sphinx_lua_ls-3.1.0/test/roots/test-autodoc-emmylua/lua/foo/x.lua +7 -0
  64. sphinx_lua_ls-3.1.0/test/roots/test-autodoc-emmylua/lua/global_tables.lua +16 -0
  65. sphinx_lua_ls-3.1.0/test/roots/test-autodoc-emmylua/lua/globals.lua +16 -0
  66. sphinx_lua_ls-3.1.0/test/roots/test-autodoc-emmylua/lua/globals_2.lua +13 -0
  67. sphinx_lua_ls-3.1.0/test/roots/test-autodoc-emmylua/lua/incongruent_export.lua +9 -0
  68. sphinx_lua_ls-3.1.0/test/roots/test-autodoc-emmylua/lua/member_ordering.lua +24 -0
  69. sphinx_lua_ls-3.1.0/test/roots/test-autodoc-emmylua/lua/module_title.lua +9 -0
  70. sphinx_lua_ls-3.1.0/test/roots/test-autodoc-emmylua/lua/nested_modules.lua +14 -0
  71. sphinx_lua_ls-3.1.0/test/roots/test-autodoc-emmylua/lua/nesting.lua +58 -0
  72. sphinx_lua_ls-3.1.0/test/roots/test-autodoc-emmylua/lua/object_types.lua +139 -0
  73. sphinx_lua_ls-3.1.0/test/roots/test-autodoc-emmylua/lua/relative_resolve.lua +19 -0
  74. sphinx_lua_ls-3.1.0/test/roots/test-autodoc-emmylua/lua/signatures.lua +35 -0
  75. sphinx_lua_ls-3.1.0/test/roots/test-autodoc-emmylua/lua/using.lua +11 -0
  76. {sphinx_lua_ls-2.0.1/test/roots/test-autodoc → sphinx_lua_ls-3.1.0/test/roots/test-autodoc-emmylua}/src/autoindex.rst +2 -2
  77. sphinx_lua_ls-3.1.0/test/roots/test-autodoc-emmylua/src/global_tables.rst +9 -0
  78. sphinx_lua_ls-3.1.0/test/roots/test-autodoc-emmylua/src/globals.rst +9 -0
  79. sphinx_lua_ls-3.1.0/test/roots/test-autodoc-emmylua/src/incongruent_export.rst +10 -0
  80. {sphinx_lua_ls-2.0.1/test/roots/test-autodoc → sphinx_lua_ls-3.1.0/test/roots/test-autodoc-emmylua}/src/object_types.rst +1 -1
  81. sphinx_lua_ls-3.1.0/test/roots/test-autodoc-emmylua/src/require.rst +9 -0
  82. sphinx_lua_ls-3.1.0/test/roots/test-autodoc-emmylua/src/signatures.rst +55 -0
  83. sphinx_lua_ls-3.1.0/test/roots/test-autodoc-emmylua/src/using.rst +16 -0
  84. {sphinx_lua_ls-2.0.1/test/roots/test-autodoc-settings → sphinx_lua_ls-3.1.0/test/roots/test-autodoc-roots}/conf.py +2 -0
  85. sphinx_lua_ls-3.1.0/test/roots/test-autodoc-settings/conf.py +7 -0
  86. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/test/roots/test-autodoc-settings/lua/autodoc.lua +6 -4
  87. sphinx_lua_ls-3.1.0/test/roots/test-doc/Makefile +20 -0
  88. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/test/roots/test-doc/conf.py +2 -0
  89. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/test/roots/test-doc/index.rst +1 -1
  90. sphinx_lua_ls-3.1.0/test/roots/test-doc/make.bat +35 -0
  91. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/test/roots/test-doc/src/autoindex.rst +25 -0
  92. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/test/roots/test-doc/src/directives.rst +43 -0
  93. sphinx_lua_ls-3.1.0/test/roots/test-doc/src/inherited.rst +57 -0
  94. sphinx_lua_ls-3.1.0/test/roots/test-intersphinx/Makefile +20 -0
  95. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/test/roots/test-intersphinx/conf.py +2 -0
  96. sphinx_lua_ls-3.1.0/test/roots/test-intersphinx/make.bat +35 -0
  97. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/test/test_parse.py +4 -4
  98. sphinx_lua_ls-3.1.0/test/test_regression/apidoc-md-sep.yml +45 -0
  99. sphinx_lua_ls-3.1.0/test/test_regression/apidoc-md.yml +10 -0
  100. sphinx_lua_ls-3.1.0/test/test_regression/apidoc-rst-sep.yml +50 -0
  101. sphinx_lua_ls-3.1.0/test/test_regression/apidoc-rst.yml +11 -0
  102. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/test/test_regression/autodoc-annotations.html +81 -36
  103. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/test/test_regression/autodoc-autoindex.html +46 -46
  104. sphinx_lua_ls-3.1.0/test/test_regression/autodoc-emmylua-annotations.html +418 -0
  105. sphinx_lua_ls-3.1.0/test/test_regression/autodoc-emmylua-autoindex.html +960 -0
  106. sphinx_lua_ls-3.1.0/test/test_regression/autodoc-emmylua-global_tables.html +96 -0
  107. sphinx_lua_ls-3.1.0/test/test_regression/autodoc-emmylua-globals.html +113 -0
  108. sphinx_lua_ls-3.1.0/test/test_regression/autodoc-emmylua-incongruent_export.html +85 -0
  109. sphinx_lua_ls-3.1.0/test/test_regression/autodoc-emmylua-member_ordering.html +666 -0
  110. sphinx_lua_ls-3.1.0/test/test_regression/autodoc-emmylua-module_title.html +115 -0
  111. sphinx_lua_ls-3.1.0/test/test_regression/autodoc-emmylua-nested_modules.html +71 -0
  112. sphinx_lua_ls-3.1.0/test/test_regression/autodoc-emmylua-nesting.html +480 -0
  113. sphinx_lua_ls-3.1.0/test/test_regression/autodoc-emmylua-nesting_recursive.html +966 -0
  114. sphinx_lua_ls-3.1.0/test/test_regression/autodoc-emmylua-object_types.html +1953 -0
  115. sphinx_lua_ls-3.1.0/test/test_regression/autodoc-emmylua-relative_resolve.html +67 -0
  116. sphinx_lua_ls-3.1.0/test/test_regression/autodoc-emmylua-require.html +50 -0
  117. sphinx_lua_ls-3.1.0/test/test_regression/autodoc-emmylua-signatures.html +1187 -0
  118. sphinx_lua_ls-3.1.0/test/test_regression/autodoc-emmylua-using.html +41 -0
  119. sphinx_lua_ls-3.1.0/test/test_regression/autodoc-globals.html +113 -0
  120. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/test/test_regression/autodoc-member_ordering.html +92 -40
  121. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/test/test_regression/autodoc-module_title.html +18 -8
  122. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/test/test_regression/autodoc-nested_modules.html +9 -4
  123. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/test/test_regression/autodoc-nesting.html +20 -14
  124. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/test/test_regression/autodoc-nesting_recursive.html +48 -40
  125. sphinx_lua_ls-3.1.0/test/test_regression/autodoc-object_types.html +2081 -0
  126. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/test/test_regression/autodoc-relative_resolve.html +3 -1
  127. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/test/test_regression/autodoc-roots-default.html.html +18 -8
  128. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/test/test_regression/autodoc-roots-single-root.html.html +9 -4
  129. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/test/test_regression/autodoc-settings-annotation.html.html +10 -4
  130. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/test/test_regression/autodoc-settings-no-recursion.html.html +1 -0
  131. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/test/test_regression/autodoc-settings-simple.html.html +10 -4
  132. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/test/test_regression/doc-annotations.html +2 -0
  133. sphinx_lua_ls-3.1.0/test/test_regression/doc-autoindex.html +419 -0
  134. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/test/test_regression/doc-directives.html +2047 -1132
  135. sphinx_lua_ls-3.1.0/test/test_regression/doc-inherited.html +230 -0
  136. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/test/test_regression/doc-modules.html +7 -0
  137. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/test/test_regression/doc-refs.html +7 -0
  138. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/test/test_regression.py +102 -0
  139. sphinx_lua_ls-2.0.1/.vscode/settings.json +0 -3
  140. sphinx_lua_ls-2.0.1/CHANGELOG.md +0 -50
  141. sphinx_lua_ls-2.0.1/docs/source/index.rst +0 -850
  142. sphinx_lua_ls-2.0.1/sphinx_lua_ls/apidoc.py +0 -151
  143. sphinx_lua_ls-2.0.1/sphinx_lua_ls/domain.py +0 -1193
  144. sphinx_lua_ls-2.0.1/sphinx_lua_ls/intersphinx.py +0 -202
  145. sphinx_lua_ls-2.0.1/sphinx_lua_ls/objtree.py +0 -683
  146. sphinx_lua_ls-2.0.1/sphinx_lua_ls.egg-info/SOURCES.txt +0 -101
  147. sphinx_lua_ls-2.0.1/test/roots/test-autodoc/lua/object_types.lua +0 -139
  148. sphinx_lua_ls-2.0.1/test/roots/test-doc/mod.lua +0 -86
  149. sphinx_lua_ls-2.0.1/test/roots/test-doc/src/intersphinx.rst +0 -6
  150. sphinx_lua_ls-2.0.1/test/test_regression/autodoc-object_types.html +0 -1918
  151. sphinx_lua_ls-2.0.1/test/test_regression/doc-autoindex.html +0 -178
  152. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/.gitignore +0 -0
  153. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/.pre-commit-config.yaml +0 -0
  154. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/LICENSE +0 -0
  155. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/README.md +0 -0
  156. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/conftest.py +0 -0
  157. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/docs/Makefile +0 -0
  158. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/docs/make.bat +0 -0
  159. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/docs/source/_extra/robots.txt +0 -0
  160. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/setup.cfg +0 -0
  161. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/sphinx_lua_ls/py.typed +0 -0
  162. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/sphinx_lua_ls/static/lua.css +0 -0
  163. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/sphinx_lua_ls.egg-info/dependency_links.txt +0 -0
  164. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/sphinx_lua_ls.egg-info/top_level.txt +0 -0
  165. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/test/conftest.py +0 -0
  166. {sphinx_lua_ls-2.0.1/test/roots/test-autodoc-roots → sphinx_lua_ls-3.1.0/test/roots/test-apidoc}/Makefile +0 -0
  167. {sphinx_lua_ls-2.0.1/test/roots/test-autodoc-roots → sphinx_lua_ls-3.1.0/test/roots/test-apidoc}/make.bat +0 -0
  168. {sphinx_lua_ls-2.0.1/test/roots/test-intersphinx → sphinx_lua_ls-3.1.0/test/roots/test-autodoc}/Makefile +0 -0
  169. {sphinx_lua_ls-2.0.1/test/roots/test-intersphinx → sphinx_lua_ls-3.1.0/test/roots/test-autodoc}/make.bat +0 -0
  170. {sphinx_lua_ls-2.0.1/test/roots/test-autodoc-settings → sphinx_lua_ls-3.1.0/test/roots/test-autodoc-emmylua}/Makefile +0 -0
  171. {sphinx_lua_ls-2.0.1/test/roots/test-autodoc-settings → sphinx_lua_ls-3.1.0/test/roots/test-autodoc-emmylua}/make.bat +0 -0
  172. {sphinx_lua_ls-2.0.1/test/roots/test-autodoc → sphinx_lua_ls-3.1.0/test/roots/test-autodoc-emmylua}/src/annotations.rst +0 -0
  173. {sphinx_lua_ls-2.0.1/test/roots/test-autodoc → sphinx_lua_ls-3.1.0/test/roots/test-autodoc-emmylua}/src/member_ordering.rst +0 -0
  174. {sphinx_lua_ls-2.0.1/test/roots/test-autodoc → sphinx_lua_ls-3.1.0/test/roots/test-autodoc-emmylua}/src/module_title.rst +0 -0
  175. {sphinx_lua_ls-2.0.1/test/roots/test-autodoc → sphinx_lua_ls-3.1.0/test/roots/test-autodoc-emmylua}/src/nested_modules.rst +0 -0
  176. {sphinx_lua_ls-2.0.1/test/roots/test-autodoc → sphinx_lua_ls-3.1.0/test/roots/test-autodoc-emmylua}/src/nesting.rst +0 -0
  177. {sphinx_lua_ls-2.0.1/test/roots/test-autodoc → sphinx_lua_ls-3.1.0/test/roots/test-autodoc-emmylua}/src/nesting_recursive.rst +0 -0
  178. {sphinx_lua_ls-2.0.1/test/roots/test-autodoc → sphinx_lua_ls-3.1.0/test/roots/test-autodoc-emmylua}/src/relative_resolve.rst +0 -0
  179. {sphinx_lua_ls-2.0.1/test/roots/test-autodoc → sphinx_lua_ls-3.1.0/test/roots/test-autodoc-roots}/Makefile +0 -0
  180. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/test/roots/test-autodoc-roots/index.rst +0 -0
  181. {sphinx_lua_ls-2.0.1/test/roots/test-autodoc-roots → sphinx_lua_ls-3.1.0/test/roots/test-autodoc-roots/lua}/root_1/autodoc.lua +0 -0
  182. {sphinx_lua_ls-2.0.1/test/roots/test-autodoc-roots → sphinx_lua_ls-3.1.0/test/roots/test-autodoc-roots/lua}/root_2/autodoc.lua +0 -0
  183. {sphinx_lua_ls-2.0.1/test/roots/test-autodoc → sphinx_lua_ls-3.1.0/test/roots/test-autodoc-roots}/make.bat +0 -0
  184. {sphinx_lua_ls-2.0.1/test/roots/test-doc → sphinx_lua_ls-3.1.0/test/roots/test-autodoc-settings}/Makefile +0 -0
  185. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/test/roots/test-autodoc-settings/index.rst +0 -0
  186. {sphinx_lua_ls-2.0.1/test/roots/test-doc → sphinx_lua_ls-3.1.0/test/roots/test-autodoc-settings}/make.bat +0 -0
  187. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/test/roots/test-doc/src/annotations.rst +0 -0
  188. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/test/roots/test-doc/src/modules.rst +0 -0
  189. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/test/roots/test-doc/src/refs.rst +0 -0
  190. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/test/roots/test-intersphinx/index.rst +0 -0
  191. {sphinx_lua_ls-2.0.1 → sphinx_lua_ls-3.1.0}/test/test_regression/autodoc-roots-no-roots.html.html +0 -0
@@ -32,11 +32,17 @@ jobs:
32
32
  - name: Install dependencies
33
33
  run: python -m pip install '.'
34
34
  - name: Download LuaLs for Linux
35
- run: python sphinx_lua_ls/lua_ls.py linux x86_64 ~/lua_ls_release/ubuntu-latest
35
+ run: python sphinx_lua_ls/lua_ls.py linux x86_64 --runtime luals ~/lua_ls_release/ubuntu-latest
36
36
  - name: Download LuaLs for Windows
37
- run: python sphinx_lua_ls/lua_ls.py win32 amd64 ~/lua_ls_release/windows-latest
37
+ run: python sphinx_lua_ls/lua_ls.py win32 amd64 --runtime luals ~/lua_ls_release/windows-latest
38
38
  - name: Download LuaLs for MacOs
39
- run: python sphinx_lua_ls/lua_ls.py darwin x86_64 ~/lua_ls_release/macos-latest
39
+ run: python sphinx_lua_ls/lua_ls.py darwin arm --runtime luals ~/lua_ls_release/macos-latest
40
+ - name: Download EmmyLua for Linux
41
+ run: python sphinx_lua_ls/lua_ls.py linux x86_64 --runtime emmylua ~/lua_ls_release/ubuntu-latest
42
+ - name: Download EmmyLua for Windows
43
+ run: python sphinx_lua_ls/lua_ls.py win32 amd64 --runtime emmylua ~/lua_ls_release/windows-latest
44
+ - name: Download EmmyLua for MacOs
45
+ run: python sphinx_lua_ls/lua_ls.py darwin arm --runtime emmylua ~/lua_ls_release/macos-latest
40
46
  - name: Upload artifact
41
47
  uses: actions/upload-artifact@v4
42
48
  with:
@@ -0,0 +1,148 @@
1
+ # Changelog
2
+
3
+ ## v3.1.0
4
+
5
+ - Added pygments lexer for Lua that highlights documentation tags.
6
+
7
+ - Added option to control maximum signature length before wrapping.
8
+
9
+ - Sphinx's nitpicky mode will no longer emit warnings
10
+ for cross-references in signatures.
11
+
12
+ - Fixed generation of URL anchors to avoid duplicates.
13
+
14
+ - Fixed some edge cases in parsing of type expressions.
15
+
16
+ ## v3.0.0
17
+
18
+ - **Breaking change:** changed how `apidoc` generates file names to avoid collisions.
19
+
20
+ - Supported [EmmyLua] as an alternative backend for documentation export.
21
+
22
+ EmmyLua was recently re-implemented in Rust, and its new language server
23
+ provides some substantial benefits:
24
+
25
+ - it has stronger and more flexible type system,
26
+ - it handles aliases and enums way better than LuaLs,
27
+ - it supports namespaces,
28
+ - it exports way more metadata, including function overloads and class constructors,
29
+ - you don't have to annotate modules with `@class` and `!doctype` anymore.
30
+
31
+ I plan to use EmmyLua as the default language server since *v4.0.0*.
32
+
33
+ - Long object signatures are now broken into multiple lines.
34
+
35
+ - Supported using arbitrary types as object names, i.e.:
36
+
37
+ ```rst
38
+ .. lua:data:: [integer]: string
39
+ ```
40
+
41
+ - Added `:globals:` flag for the `lua:autoobject` directive. It will allow
42
+ automatically documenting global variables defined in a module.
43
+
44
+ - The `lua:autoindex` directive now lists globals defined in a module.
45
+
46
+ - Added support for documenting class constructors:
47
+
48
+ ```rst
49
+ .. lua:class:: Foo(a, b, ...)
50
+ ```
51
+
52
+ - Added directive for enums.
53
+
54
+ - Supported generic parameters for functions, classes, aliases and enums:
55
+
56
+ ```rst
57
+ .. lua:class:: Foo<T>
58
+ ```
59
+
60
+ - Improved linking to Lua language documentation to take into account
61
+ whether an item is supported for the given Lua version.
62
+
63
+ - Added the `lua:lua` role to compensate for MySt not supporting default roles.
64
+
65
+ If Lua is your primary domain cross-referencing from markdown can be done like this:
66
+
67
+ ```md
68
+ Reference to a {lua}`logging.Logger.info`.
69
+ ```
70
+
71
+ - Added the `lua:other-inherited-members` directive and `:inherited-members-table:`
72
+ flag for the `lua:autoobject` directive.
73
+
74
+ These allow listing all members that were inherited by a class but weren't
75
+ documented within the class body (see [#3]).
76
+
77
+ - Supported markdown output for `apidoc`.
78
+
79
+ - Added option to separate module members into their own files for `apidoc`.
80
+
81
+ [EmmyLua]: https://github.com/EmmyLuaLs/emmylua-analyzer-rust/
82
+ [#3]: https://github.com/taminomara/sphinx-lua-ls/issues/3
83
+
84
+ **Migrating to 3.0.0:**
85
+
86
+ - If you're using `apidoc`, you'll need to update links to your documentation.
87
+
88
+ - You'll need to explicitly specify which language server to use
89
+ by including `lua_ls_backend` to your `conf.py`.
90
+
91
+ ## v2.0.1
92
+
93
+ - Fixed documentation not being rebuilt after changing lua source code.
94
+
95
+ ## v2.0.0
96
+
97
+ - **Breaking change:** don't implicitly convert classes that're derived from `table`
98
+ to modules. Users should use a `!doctype` comment instead.
99
+
100
+ - **Breaking change:** disallow nesting modules inside classes.
101
+
102
+ - Added `autoindex` directive.
103
+
104
+ - Added `apidoc` functionality.
105
+
106
+ - Improved test coverage and fixed found bugs.
107
+
108
+ **Migrating to 2.0.0:**
109
+
110
+ In your Lua code base, perform global replace by regexp:
111
+
112
+ ```
113
+ ^(\s*)---\s*@class\s*(.+): table$
114
+ ```
115
+
116
+ to
117
+
118
+ ```
119
+ $1--- !doctype module
120
+ $1--- @class $2
121
+ ```
122
+
123
+ Make sure that you only use `!doctype module` on the top-level
124
+ tables that can be imported via `require`. On other objects,
125
+ use `!doctype table` instead, otherwise you'll get errors that modules are not allowed within other objects.
126
+
127
+ ## v1.1.0
128
+
129
+ - Added support for `!doc` and `!doctype` comments.
130
+
131
+ - Added `:include-protected:` and `:include-package:` options for `lua:autoobject`.
132
+
133
+ - Allowed referring `lua:const` objects from `lua:attr` role.
134
+
135
+ - Fixed a bug when default options would not properly propagate
136
+ when using `lua:autoobject` with `:recurse:`.
137
+
138
+ - Fixed a bug when `lua:autoobject` would deduce incorrect module paths
139
+ when applied to non-toplevel modules.
140
+
141
+ - Fixed a bug when docstring for a class would be used for undocumented function
142
+ parameters that have this class as their type.
143
+
144
+ - Fixed types when `lua:autoobject` would infer incorrect types for `data`.
145
+
146
+ ## v1.0.0
147
+
148
+ Initial release.
@@ -22,6 +22,10 @@
22
22
  pre-commit install
23
23
  ```
24
24
 
25
+ 5. If you're not on linux, install [EmmyLua Doc Cli].
26
+
27
+ [EmmyLua Doc Cli]: https://github.com/EmmyLuaLs/emmylua-analyzer-rust/?tab=readme-ov-file#-installation
28
+
25
29
  ## Run tests
26
30
 
27
31
  To run tests, simply run `pytest` and `pyright`:
@@ -37,6 +41,12 @@ To fix code style, you can manually run pre-commit hooks:
37
41
  pre-commit run -a # Fix code style.
38
42
  ```
39
43
 
44
+ To regenerate data for regression tests, run
45
+
46
+ ```shell
47
+ pytest --regen-all
48
+ ```
49
+
40
50
 
41
51
  ## Build docs
42
52
 
@@ -1,30 +1,9 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: sphinx-lua-ls
3
- Version: 2.0.1
4
- Summary: Automatic documentation generation via LuaLS
3
+ Version: 3.1.0
4
+ Summary: Automatic documentation generation via EmmyLua/LuaLs
5
5
  Author-email: Tamika Nomara <taminomara@gmail.com>
6
- License: MIT License
7
-
8
- Copyright (c) 2018 Tamika Nomara
9
-
10
- Permission is hereby granted, free of charge, to any person obtaining a copy
11
- of this software and associated documentation files (the "Software"), to deal
12
- in the Software without restriction, including without limitation the rights
13
- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
14
- copies of the Software, and to permit persons to whom the Software is
15
- furnished to do so, subject to the following conditions:
16
-
17
- The above copyright notice and this permission notice shall be included in all
18
- copies or substantial portions of the Software.
19
-
20
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
21
- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
22
- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
23
- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
24
- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
25
- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
26
- SOFTWARE.
27
-
6
+ License-Expression: MIT
28
7
  Project-URL: Documentation, https://taminomara.github.io/sphinx-lua-ls/
29
8
  Project-URL: Issues, https://github.com/taminomara/sphinx-lua-ls/issues
30
9
  Project-URL: Source, https://github.com/taminomara/sphinx-lua-ls/
@@ -34,7 +13,6 @@ Classifier: Programming Language :: Python :: 3 :: Only
34
13
  Classifier: Programming Language :: Python :: 3
35
14
  Classifier: Programming Language :: Python :: 3.12
36
15
  Classifier: Programming Language :: Python :: 3.13
37
- Classifier: License :: OSI Approved :: MIT License
38
16
  Classifier: Intended Audience :: Developers
39
17
  Classifier: Framework :: Sphinx
40
18
  Classifier: Framework :: Sphinx :: Domain
@@ -62,10 +40,12 @@ Requires-Dist: pytest~=7.4; extra == "test"
62
40
  Requires-Dist: sybil~=6.1; extra == "test"
63
41
  Requires-Dist: pytest-regressions~=2.7; extra == "test"
64
42
  Requires-Dist: beautifulsoup4~=4.13; extra == "test"
43
+ Requires-Dist: myst-parser~=4.0; extra == "test"
65
44
  Provides-Extra: doc
66
45
  Requires-Dist: sybil~=6.1; extra == "doc"
67
46
  Requires-Dist: furo>=2024; extra == "doc"
68
47
  Requires-Dist: sphinx_design>=0.6; extra == "doc"
48
+ Requires-Dist: myst-parser~=4.0; extra == "doc"
69
49
  Dynamic: license-file
70
50
 
71
51
  # Sphinx plugin for Lua and Lua Language Server
@@ -0,0 +1,20 @@
1
+ {
2
+ "diagnostics": {
3
+ "enables": ["unknown-doc-tag"]
4
+ },
5
+ "runtime": {
6
+ "version": "Lua5.4",
7
+ "requireLikeFunction": [],
8
+ "frameworkVersions": [],
9
+ "extensions": [],
10
+ "requirePattern": [],
11
+ "classDefaultCall": {
12
+ "functionName": "__init",
13
+ "forceNonColon": true,
14
+ "forceReturnSelf": true
15
+ }
16
+ },
17
+ "doc": {
18
+ "knownTags": ["doctype", "doc"]
19
+ }
20
+ }
@@ -1,53 +1,38 @@
1
+ --- @namespace logging
2
+
1
3
  --- A generic logging module, just to demonstrate you documentation.
2
- ---
3
- --- .. lua:autoobject:: LOG_LEVEL
4
- --- :global:
5
- ---
6
- --- !doctype module
7
- --- @class logging
8
- logging = {}
4
+ local logging = {}
9
5
 
10
6
  --- Represents message severity.
11
7
  ---
12
- --- @alias logging.Level integer
13
- logging.Level = {}
8
+ --- @enum Level
9
+ logging.Level = {
10
+ --- For debug messages, hidden by default.
11
+ Debug = 1,
14
12
 
15
- --- For debug messages, hidden by default.
16
- ---
17
- --- @type logging.Level
18
- logging.Level.Debug = 1
13
+ --- For info messages.
14
+ Info = 2,
19
15
 
20
- --- For info messages.
21
- ---
22
- --- @type logging.Level
23
- logging.Level.Info = 2
16
+ --- For warnings, when behavior may be different from what users expect.
17
+ Warning = 3,
24
18
 
25
- --- For warnings, when behavior may be different from what users expect.
26
- ---
27
- --- @type logging.Level
28
- logging.Level.Warning = 3
29
-
30
- --- For errors, when the system stops working.
31
- ---
32
- --- @type logging.Level
33
- logging.Level.Error = 4
19
+ --- For errors, when the system stops working.
20
+ Error = 4,
21
+ }
34
22
 
35
23
  --- Default log level.
36
24
  ---
37
- --- @type logging.Level
25
+ --- @type Level
38
26
  LOG_LEVEL = LOG_LEVEL or logging.Level.Info
39
27
 
40
28
  --- An object for logging messages.
41
29
  ---
42
- --- @class logging.Logger
30
+ --- @class Logger
43
31
  logging.Logger = {}
44
32
 
45
- --- Create a new logger.
46
- ---
47
33
  --- @param name string name of the logger, will be added to every message.
48
34
  --- @param level logging.Level? level of the logger, equals to `LOG_LEVEL` by default.
49
- --- @return logging.Logger
50
- function logging.Logger.new(name, level) return {} end
35
+ function logging.Logger.__init(name, level) end
51
36
 
52
37
  --- Print a debug message.
53
38
  ---
@@ -0,0 +1,79 @@
1
+ Generating API references
2
+ =========================
3
+
4
+ :rst:dir:`lua:autoobject` allows recursively generating documentation,
5
+ however it all ends up on a single page. If you want to give a separate page
6
+ for every module, you'll need to create multiple ``.rst`` or ``.md`` files.
7
+ Fortunately, Sphinx-LuaLs can do this for you.
8
+
9
+ Add :py:data:`lua_ls_apidoc_roots` option to the ``conf.py``, and provide a mapping
10
+ from module names to directories (relative to the location of ``conf.py``)
11
+ where generated ``.rst`` or ``.md`` files should be placed.
12
+
13
+ For example, to generate API reference for module ``moduleName``
14
+ in directory ``moduleDirectory``, add the following:
15
+
16
+ .. tab-set::
17
+ :sync-group: lang
18
+
19
+ .. tab-item:: RST
20
+ :sync: rst
21
+
22
+ .. code-block:: python
23
+
24
+ lua_ls_apidoc_roots = {
25
+ "moduleName": "moduleDirectory",
26
+ }
27
+
28
+ .. tab-item:: Markdown
29
+ :sync: md
30
+
31
+ .. code-block:: python
32
+
33
+ lua_ls_apidoc_format = "md"
34
+ lua_ls_apidoc_roots = {
35
+ "moduleName": "moduleDirectory",
36
+ }
37
+
38
+ Upon start, Sphinx-LuaLs will recursively create ``.rst`` or ``.md`` files
39
+ in ``moduleDirectory``. ``moduleDirectory/index`` will contain reference for
40
+ ``moduleName``. Then, for every submodule of ``moduleName``, there will be another
41
+ ``.rst`` or ``.md`` generated.
42
+
43
+ .. warning::
44
+
45
+ Do not add any other files to ``moduleDirectory``, otherwise they will be deleted.
46
+
47
+ It is best to add ``moduleDirectory`` to your ``.gitignore`` file.
48
+
49
+ Don't forget to include ``moduleDirectory/index`` into a table of contents
50
+ in your main ``index.rst``/``index.md``.
51
+
52
+ Settings
53
+ --------
54
+
55
+ You can override default settings using :py:data:`lua_ls_apidoc_max_depth`,
56
+ :py:data:`lua_ls_apidoc_default_options`,
57
+ :py:data:`lua_ls_apidoc_ignored_modules`,
58
+ :py:data:`lua_ls_apidoc_separate_members`,
59
+ and :py:data:`lua_ls_apidoc_format`;
60
+ see `settings <settings.html>`_ for more info.
61
+
62
+ For example, here's how to enable documentation for members without description,
63
+ protected members, and global variables:
64
+
65
+ .. code-block:: python
66
+
67
+ lua_ls_apidoc_default_options = {
68
+ # Document members without description.
69
+ "undoc-members": "",
70
+ # Document protected members.
71
+ "protected-members": "",
72
+ # Document module's global variables.
73
+ "globals": "",
74
+ # Override default ordering.
75
+ "member-order": "alphabetical",
76
+ "module-member-order": "groupwise",
77
+ # Add table with inherited members for classes.
78
+ "inherited-members-table": "",
79
+ }