openstackdocstheme 3.5.0__tar.gz → 3.7.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 (194) hide show
  1. {openstackdocstheme-3.5.0 → openstackdocstheme-3.7.0}/PKG-INFO +19 -24
  2. {openstackdocstheme-3.5.0 → openstackdocstheme-3.7.0}/README.rst +4 -10
  3. {openstackdocstheme-3.5.0 → openstackdocstheme-3.7.0}/openstackdocstheme/__init__.py +5 -1
  4. {openstackdocstheme-3.5.0 → openstackdocstheme-3.7.0}/openstackdocstheme/ext.py +148 -78
  5. {openstackdocstheme-3.5.0 → openstackdocstheme-3.7.0}/openstackdocstheme/page_context.py +24 -17
  6. {openstackdocstheme-3.5.0 → openstackdocstheme-3.7.0}/openstackdocstheme/paths.py +5 -5
  7. {openstackdocstheme-3.5.0 → openstackdocstheme-3.7.0}/openstackdocstheme/version.py +4 -2
  8. {openstackdocstheme-3.5.0 → openstackdocstheme-3.7.0}/openstackdocstheme.egg-info/PKG-INFO +19 -24
  9. openstackdocstheme-3.7.0/openstackdocstheme.egg-info/SOURCES.txt +17 -0
  10. {openstackdocstheme-3.5.0 → openstackdocstheme-3.7.0}/openstackdocstheme.egg-info/requires.txt +2 -2
  11. openstackdocstheme-3.7.0/pyproject.toml +77 -0
  12. openstackdocstheme-3.7.0/setup.cfg +4 -0
  13. openstackdocstheme-3.5.0/.pre-commit-config.yaml +0 -32
  14. openstackdocstheme-3.5.0/.zuul.yaml +0 -108
  15. openstackdocstheme-3.5.0/AUTHORS +0 -88
  16. openstackdocstheme-3.5.0/CONTRIBUTING.rst +0 -14
  17. openstackdocstheme-3.5.0/ChangeLog +0 -812
  18. openstackdocstheme-3.5.0/HACKING.rst +0 -11
  19. openstackdocstheme-3.5.0/Makefile +0 -177
  20. openstackdocstheme-3.5.0/api-ref/source/_static/css/README.md +0 -5
  21. openstackdocstheme-3.5.0/api-ref/source/conf.py +0 -88
  22. openstackdocstheme-3.5.0/api-ref/source/image.inc +0 -163
  23. openstackdocstheme-3.5.0/api-ref/source/index.rst +0 -6
  24. openstackdocstheme-3.5.0/api-ref/source/parameters.yaml +0 -37
  25. openstackdocstheme-3.5.0/api-ref/source/service.inc +0 -152
  26. openstackdocstheme-3.5.0/api-ref/source/status.yaml +0 -17
  27. openstackdocstheme-3.5.0/api-ref/source/update-server-resp.json +0 -5
  28. openstackdocstheme-3.5.0/bindep.txt +0 -38
  29. openstackdocstheme-3.5.0/doc/requirements.txt +0 -7
  30. openstackdocstheme-3.5.0/doc/source/conf.py +0 -84
  31. openstackdocstheme-3.5.0/doc/source/demo/configure_access_and_security_for_instances.rst +0 -200
  32. openstackdocstheme-3.5.0/doc/source/demo/create_and_manage_databases.rst +0 -154
  33. openstackdocstheme-3.5.0/doc/source/demo/create_and_manage_networks.rst +0 -102
  34. openstackdocstheme-3.5.0/doc/source/demo/dashboard_demo.rst +0 -202
  35. openstackdocstheme-3.5.0/doc/source/demo/figures/dashboard-project-tab.png +0 -0
  36. openstackdocstheme-3.5.0/doc/source/demo/figures/dashboard_admin_project_tab.png +0 -0
  37. openstackdocstheme-3.5.0/doc/source/demo/figures/doc-logo-fox.jpg +0 -0
  38. openstackdocstheme-3.5.0/doc/source/demo/index.rst +0 -203
  39. openstackdocstheme-3.5.0/doc/source/demo/launch-instance.rst +0 -89
  40. openstackdocstheme-3.5.0/doc/source/demo/section_dashboard_access_and_security.rst +0 -180
  41. openstackdocstheme-3.5.0/doc/source/index.rst +0 -268
  42. openstackdocstheme-3.5.0/index.rst +0 -29
  43. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/css.html +0 -21
  44. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/footer.html +0 -56
  45. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/header.html +0 -111
  46. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/layout.html +0 -97
  47. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/license_cc.html +0 -9
  48. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/localtoc.html +0 -8
  49. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/os_search.html +0 -3
  50. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/os_search_install.html +0 -10
  51. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/os_search_mobile.html +0 -3
  52. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/script_footer.html +0 -70
  53. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/script_search.html +0 -28
  54. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/search.html +0 -42
  55. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/sidebartoc.html +0 -24
  56. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/sidebartoc_menu.html +0 -20
  57. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/sidebartoc_menu_apiref.html +0 -40
  58. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/css/bootstrap.css +0 -12057
  59. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/css/bootstrap.css.map +0 -1
  60. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/css/bootstrap.min.css +0 -6
  61. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/css/bootstrap.min.css.map +0 -1
  62. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/css/combined.css +0 -973
  63. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/css/font-awesome.css +0 -2337
  64. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/css/font-awesome.min.css +0 -4
  65. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/css/search.css +0 -49
  66. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/favicon.ico +0 -0
  67. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/fonts/.gitkeep +0 -0
  68. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/fonts/FontAwesome.otf +0 -0
  69. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/fonts/fontawesome-webfont.eot +0 -0
  70. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/fonts/fontawesome-webfont.svg +0 -685
  71. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/fonts/fontawesome-webfont.ttf +0 -0
  72. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/fonts/fontawesome-webfont.woff +0 -0
  73. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/fonts/fontawesome-webfont.woff2 +0 -0
  74. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/fonts/glyphicons-halflings-regular.eot +0 -0
  75. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/fonts/glyphicons-halflings-regular.svg +0 -288
  76. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/fonts/glyphicons-halflings-regular.ttf +0 -0
  77. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/fonts/glyphicons-halflings-regular.woff +0 -0
  78. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/fonts/glyphicons-halflings-regular.woff2 +0 -0
  79. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/images/docs/license.png +0 -0
  80. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/images/docs/superuser1.png +0 -0
  81. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/images/docs/superuser2.png +0 -0
  82. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/images/docs/superuser3.png +0 -0
  83. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/images/docs/superuser4.png +0 -0
  84. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/images/footer-facebook-hover.png +0 -0
  85. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/images/footer-facebook.png +0 -0
  86. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/images/footer-linkedin-hover.png +0 -0
  87. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/images/footer-linkedin.png +0 -0
  88. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/images/footer-twitter-hover.png +0 -0
  89. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/images/footer-twitter.png +0 -0
  90. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/images/footer-youtube-hover.png +0 -0
  91. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/images/footer-youtube.png +0 -0
  92. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/images/loading.gif +0 -0
  93. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/images/logo-full.png +0 -0
  94. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/images/logo-full.svg +0 -57
  95. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/images/logo-vert.png +0 -0
  96. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/images/logo-vert.svg +0 -57
  97. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/images/openstack-logo-full.png +0 -0
  98. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/images/openstack-logo-full.svg +0 -57
  99. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/images/openstack-logo-vert.png +0 -0
  100. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/images/openstack-logo-vert.svg +0 -57
  101. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/images/search-icon.png +0 -0
  102. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/js/bootstrap.bundle.min.js +0 -7
  103. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/js/bootstrap.bundle.min.js.map +0 -1
  104. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/js/bootstrap.js +0 -4494
  105. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/js/bootstrap.min.js +0 -7
  106. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/js/docs.js +0 -92
  107. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/js/jquery-3.2.1.js +0 -10253
  108. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/js/jquery-3.2.1.min.js +0 -4
  109. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/static/js/navigation.js +0 -56
  110. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/theme.conf +0 -15
  111. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs/titlerow.html +0 -35
  112. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs_pdf/logo-full.png +0 -0
  113. openstackdocstheme-3.5.0/openstackdocstheme/theme/openstackdocs_pdf/pdftheme.sty +0 -67
  114. openstackdocstheme-3.5.0/openstackdocstheme/theme/starlingxdocs/footer.html +0 -42
  115. openstackdocstheme-3.5.0/openstackdocstheme/theme/starlingxdocs/header.html +0 -40
  116. openstackdocstheme-3.5.0/openstackdocstheme/theme/starlingxdocs/sidebartoc_menu.html +0 -6
  117. openstackdocstheme-3.5.0/openstackdocstheme/theme/starlingxdocs/sidebartoc_menu_apiref.html +0 -10
  118. openstackdocstheme-3.5.0/openstackdocstheme/theme/starlingxdocs/static/css/combined.css +0 -973
  119. openstackdocstheme-3.5.0/openstackdocstheme/theme/starlingxdocs/static/images/StarlingX_Logo_RGB_Horizontal_2color.png +0 -0
  120. openstackdocstheme-3.5.0/openstackdocstheme/theme/starlingxdocs/static/images/StarlingX_Logo_RGB_Horizontal_2color.svg +0 -1
  121. openstackdocstheme-3.5.0/openstackdocstheme/theme/starlingxdocs/static/images/StarlingX_Logo_RGB_Stacked_2color.png +0 -0
  122. openstackdocstheme-3.5.0/openstackdocstheme/theme/starlingxdocs/static/images/StarlingX_Logo_RGB_Stacked_2color.svg +0 -1
  123. openstackdocstheme-3.5.0/openstackdocstheme/theme/starlingxdocs/static/images/logo-full.png +0 -0
  124. openstackdocstheme-3.5.0/openstackdocstheme/theme/starlingxdocs/static/images/logo-full.svg +0 -1
  125. openstackdocstheme-3.5.0/openstackdocstheme/theme/starlingxdocs/static/images/logo-vert.png +0 -0
  126. openstackdocstheme-3.5.0/openstackdocstheme/theme/starlingxdocs/static/images/logo-vert.svg +0 -1
  127. openstackdocstheme-3.5.0/openstackdocstheme/theme/starlingxdocs/stx_search.html +0 -3
  128. openstackdocstheme-3.5.0/openstackdocstheme/theme/starlingxdocs/stx_search_install.html +0 -10
  129. openstackdocstheme-3.5.0/openstackdocstheme/theme/starlingxdocs/stx_search_mobile.html +0 -3
  130. openstackdocstheme-3.5.0/openstackdocstheme/theme/starlingxdocs/theme.conf +0 -14
  131. openstackdocstheme-3.5.0/openstackdocstheme/theme/starlingxdocs/titlerow.html +0 -32
  132. openstackdocstheme-3.5.0/openstackdocstheme/theme/starlingxdocs_pdf/logo-full.png +0 -0
  133. openstackdocstheme-3.5.0/openstackdocstheme/theme/starlingxdocs_pdf/logo-full.svg +0 -1
  134. openstackdocstheme-3.5.0/openstackdocstheme/theme/starlingxdocs_pdf/pdftheme.sty +0 -67
  135. openstackdocstheme-3.5.0/openstackdocstheme.egg-info/SOURCES.txt +0 -190
  136. openstackdocstheme-3.5.0/openstackdocstheme.egg-info/not-zip-safe +0 -1
  137. openstackdocstheme-3.5.0/openstackdocstheme.egg-info/pbr.json +0 -1
  138. openstackdocstheme-3.5.0/pyproject.toml +0 -6
  139. openstackdocstheme-3.5.0/releasenotes/notes/add-openstackdocs_auto_name-option-efbd1cf9a171f079.yaml +0 -6
  140. openstackdocstheme-3.5.0/releasenotes/notes/add-openstackdocs_auto_version-option-fd03f20373eede39.yaml +0 -13
  141. openstackdocstheme-3.5.0/releasenotes/notes/add-reno-8da9bd3ccb7bbeab.yaml +0 -3
  142. openstackdocstheme-3.5.0/releasenotes/notes/add-starlingxdocs-10a33318f8630486.yaml +0 -11
  143. openstackdocstheme-3.5.0/releasenotes/notes/add-translations-9238b0f56b677a6b.yaml +0 -24
  144. openstackdocstheme-3.5.0/releasenotes/notes/allow-disabling-toc-in-body-d98d3a6e633fa28e.yaml +0 -14
  145. openstackdocstheme-3.5.0/releasenotes/notes/autoconfigure-settings-7083fdeeb121da89.yaml +0 -17
  146. openstackdocstheme-3.5.0/releasenotes/notes/badge-6f8713da36a7e570.yaml +0 -6
  147. openstackdocstheme-3.5.0/releasenotes/notes/bug-project-e9ff50f6149d2be1.yaml +0 -5
  148. openstackdocstheme-3.5.0/releasenotes/notes/bug-title-fdbefea0408e2cbf.yaml +0 -13
  149. openstackdocstheme-3.5.0/releasenotes/notes/bug_project-d26160cfe5324694.yaml +0 -4
  150. openstackdocstheme-3.5.0/releasenotes/notes/css-cleanup-7fb30a2d1208bb4d.yaml +0 -5
  151. openstackdocstheme-3.5.0/releasenotes/notes/custom-bug-link-ec64bdf9ce357d16.yaml +0 -18
  152. openstackdocstheme-3.5.0/releasenotes/notes/disable_analytics-45d98d6fab71d2b1.yaml +0 -5
  153. openstackdocstheme-3.5.0/releasenotes/notes/do-not-display-local-toc-title-without-subtitles-4e1fc48705d66289.yaml +0 -5
  154. openstackdocstheme-3.5.0/releasenotes/notes/doc-bug-template-7234e7f00e0ff599.yaml +0 -8
  155. openstackdocstheme-3.5.0/releasenotes/notes/double-backticks-not-red-5ce6dbc828221929.yaml +0 -5
  156. openstackdocstheme-3.5.0/releasenotes/notes/drop-python-2-7-73d3113c69d724d6.yaml +0 -5
  157. openstackdocstheme-3.5.0/releasenotes/notes/get_openstack_logo_path-6cdb6538bc5893c3.yaml +0 -5
  158. openstackdocstheme-3.5.0/releasenotes/notes/last-updated-via-git-245fb14be3770a19.yaml +0 -6
  159. openstackdocstheme-3.5.0/releasenotes/notes/latex_engine-cc35cb3a4ad2fa00.yaml +0 -5
  160. openstackdocstheme-3.5.0/releasenotes/notes/local-project-search-e6f00a84f2eed0a6.yaml +0 -12
  161. openstackdocstheme-3.5.0/releasenotes/notes/lp1516819-b4bb7b0f10004cef.yaml +0 -4
  162. openstackdocstheme-3.5.0/releasenotes/notes/merge-latex-options-242f10c932f0e6af.yaml +0 -9
  163. openstackdocstheme-3.5.0/releasenotes/notes/norelease-ccd7722c078a73a2.yaml +0 -5
  164. openstackdocstheme-3.5.0/releasenotes/notes/opendev-5c528b2b4c737d59.yaml +0 -4
  165. openstackdocstheme-3.5.0/releasenotes/notes/pdf-version-56c223128dff8357.yaml +0 -6
  166. openstackdocstheme-3.5.0/releasenotes/notes/pdf_link-c6b0ed36dd12b0ef.yaml +0 -7
  167. openstackdocstheme-3.5.0/releasenotes/notes/renamed-opts-bbf5d1390ed6ba71.yaml +0 -15
  168. openstackdocstheme-3.5.0/releasenotes/notes/side-bar-config-d7e66388e252cadf.yaml +0 -16
  169. openstackdocstheme-3.5.0/releasenotes/notes/sidebar-top-page-link-252532ddf42a5acf.yaml +0 -5
  170. openstackdocstheme-3.5.0/releasenotes/notes/sidebar_dropdown_apiref-993b4dba4c0369f6.yaml +0 -29
  171. openstackdocstheme-3.5.0/releasenotes/notes/sidebarlinks-db0a8463f32ab95d.yaml +0 -4
  172. openstackdocstheme-3.5.0/releasenotes/notes/source_date_epoch-1078730ca0b29a4e.yaml +0 -6
  173. openstackdocstheme-3.5.0/releasenotes/notes/storyboard-5f67da8941aec6ae.yaml +0 -4
  174. openstackdocstheme-3.5.0/releasenotes/notes/storyboard-string-643a47e957b64557.yaml +0 -6
  175. openstackdocstheme-3.5.0/releasenotes/notes/storyboard-url-cee60d9449ec2980.yaml +0 -6
  176. openstackdocstheme-3.5.0/releasenotes/notes/strip-html-tags-from-navigation-titles-929c92a339413015.yaml +0 -5
  177. openstackdocstheme-3.5.0/releasenotes/notes/version-dropdown-1aa39974f524dd75.yaml +0 -23
  178. openstackdocstheme-3.5.0/releasenotes/source/_static/.placeholder +0 -0
  179. openstackdocstheme-3.5.0/releasenotes/source/_templates/.placeholder +0 -0
  180. openstackdocstheme-3.5.0/releasenotes/source/conf.py +0 -284
  181. openstackdocstheme-3.5.0/releasenotes/source/current.rst +0 -5
  182. openstackdocstheme-3.5.0/releasenotes/source/historic.rst +0 -125
  183. openstackdocstheme-3.5.0/releasenotes/source/index.rst +0 -9
  184. openstackdocstheme-3.5.0/requirements.txt +0 -3
  185. openstackdocstheme-3.5.0/setup.cfg +0 -37
  186. openstackdocstheme-3.5.0/setup.py +0 -19
  187. openstackdocstheme-3.5.0/tox.ini +0 -90
  188. {openstackdocstheme-3.5.0 → openstackdocstheme-3.7.0}/LICENSE +0 -0
  189. {openstackdocstheme-3.5.0 → openstackdocstheme-3.7.0}/bin/docstheme-build-pdf +0 -0
  190. {openstackdocstheme-3.5.0 → openstackdocstheme-3.7.0}/bin/docstheme-build-translated.sh +0 -0
  191. {openstackdocstheme-3.5.0 → openstackdocstheme-3.7.0}/bin/docstheme-lang-display-name.py +0 -0
  192. /openstackdocstheme-3.5.0/doc/source/_static/css/.placeholder → /openstackdocstheme-3.7.0/openstackdocstheme/py.typed +0 -0
  193. {openstackdocstheme-3.5.0 → openstackdocstheme-3.7.0}/openstackdocstheme.egg-info/dependency_links.txt +0 -0
  194. {openstackdocstheme-3.5.0 → openstackdocstheme-3.7.0}/openstackdocstheme.egg-info/top_level.txt +0 -0
@@ -1,42 +1,38 @@
1
- Metadata-Version: 2.1
1
+ Metadata-Version: 2.4
2
2
  Name: openstackdocstheme
3
- Version: 3.5.0
3
+ Version: 3.7.0
4
4
  Summary: OpenStack Docs Theme
5
- Home-page: https://docs.openstack.org/openstackdocstheme/latest/
6
- Author: OpenStack
7
- Author-email: openstack-discuss@lists.openstack.org
5
+ Author-email: OpenStack <openstack-discuss@lists.openstack.org>
6
+ License-Expression: Apache-2.0
7
+ Project-URL: Homepage, https://docs.openstack.org/openstackdocstheme
8
+ Project-URL: Repository, https://opendev.org/openstack/openstackdocstheme
8
9
  Classifier: Environment :: OpenStack
9
10
  Classifier: Intended Audience :: Information Technology
10
11
  Classifier: Intended Audience :: System Administrators
11
- Classifier: License :: OSI Approved :: Apache Software License
12
12
  Classifier: Operating System :: POSIX :: Linux
13
13
  Classifier: Programming Language :: Python
14
14
  Classifier: Programming Language :: Python :: 3
15
- Classifier: Programming Language :: Python :: 3.8
16
- Classifier: Programming Language :: Python :: 3.9
17
- Classifier: Programming Language :: Python :: 3.10
18
15
  Classifier: Programming Language :: Python :: 3.11
19
16
  Classifier: Programming Language :: Python :: 3.12
20
- Classifier: Programming Language :: Python :: 3 :: Only
17
+ Classifier: Programming Language :: Python :: 3.13
18
+ Classifier: Programming Language :: Python :: 3.14
19
+ Classifier: Programming Language :: Python :: 3.15
21
20
  Classifier: Topic :: Documentation
22
- Requires-Python: >=3.8
21
+ Classifier: Typing :: Typed
22
+ Requires-Python: >=3.11
23
+ Description-Content-Type: text/x-rst
23
24
  License-File: LICENSE
24
- Requires-Dist: pbr!=2.1.0,>=2.0.0
25
25
  Requires-Dist: dulwich>=0.15.0
26
- Requires-Dist: sphinx>=6.0.0
27
-
28
- ========================
29
- Team and repository tags
30
- ========================
31
-
32
- .. image:: https://governance.openstack.org/tc/badges/openstackdocstheme.svg
33
- :target: https://governance.openstack.org/tc/reference/tags/index.html
34
-
35
- .. Change things from this point on
26
+ Requires-Dist: pbr!=2.1.0,>=2.0.0
27
+ Requires-Dist: sphinx>=8.0.0
28
+ Dynamic: license-file
36
29
 
30
+ ==========================================
37
31
  Open Infrastructure Projects Sphinx Themes
38
32
  ==========================================
39
33
 
34
+ .. image:: https://governance.openstack.org/tc/badges/openstackdocstheme.svg
35
+
40
36
  Theme and extension support for Sphinx documentation that is published by
41
37
  Open Infrastructure Foundation projects.
42
38
 
@@ -51,7 +47,7 @@ Intended for use by OpenStack `projects governed by the Technical Committee`_.
51
47
  .. _`projects governed by the Technical Committee`: https://governance.openstack.org/tc/reference/projects/index.html
52
48
 
53
49
  StarlingX docs.starlingx.io Sphinx Theme
54
- -----------------------------------------
50
+ ----------------------------------------
55
51
 
56
52
  Theme support for Sphinx documentation that is published to
57
53
  docs.starlingx.io.
@@ -68,4 +64,3 @@ References
68
64
  * Release notes: https://docs.openstack.org/releasenotes/openstackdocstheme/
69
65
  * Source: https://opendev.org/openstack/openstackdocstheme
70
66
  * Bugs: https://launchpad.net/openstack-doc-tools
71
-
@@ -1,15 +1,9 @@
1
- ========================
2
- Team and repository tags
3
- ========================
4
-
5
- .. image:: https://governance.openstack.org/tc/badges/openstackdocstheme.svg
6
- :target: https://governance.openstack.org/tc/reference/tags/index.html
7
-
8
- .. Change things from this point on
9
-
1
+ ==========================================
10
2
  Open Infrastructure Projects Sphinx Themes
11
3
  ==========================================
12
4
 
5
+ .. image:: https://governance.openstack.org/tc/badges/openstackdocstheme.svg
6
+
13
7
  Theme and extension support for Sphinx documentation that is published by
14
8
  Open Infrastructure Foundation projects.
15
9
 
@@ -24,7 +18,7 @@ Intended for use by OpenStack `projects governed by the Technical Committee`_.
24
18
  .. _`projects governed by the Technical Committee`: https://governance.openstack.org/tc/reference/projects/index.html
25
19
 
26
20
  StarlingX docs.starlingx.io Sphinx Theme
27
- -----------------------------------------
21
+ ----------------------------------------
28
22
 
29
23
  Theme support for Sphinx documentation that is published to
30
24
  docs.starlingx.io.
@@ -12,6 +12,10 @@
12
12
  # License for the specific language governing permissions and limitations
13
13
  # under the License.
14
14
 
15
+ from typing import Any
16
+
17
+ from sphinx import application
18
+
15
19
  from . import ext
16
20
  from . import page_context
17
21
  from .paths import * # noqa
@@ -21,7 +25,7 @@ from .version import version_info
21
25
  __version__ = version_info.version_string()
22
26
 
23
27
 
24
- def setup(app):
28
+ def setup(app: application.Sphinx) -> dict[str, Any]:
25
29
  ext.setup(app)
26
30
  page_context.setup(app)
27
31
  return {
@@ -16,58 +16,65 @@ import configparser
16
16
  import os
17
17
  import subprocess
18
18
  import textwrap
19
+ import tomllib
20
+ from typing import Any
19
21
 
22
+ from docutils import nodes
23
+ import dulwich.errors
20
24
  import dulwich.repo
21
25
  from pbr import packaging
26
+ from sphinx import application
27
+ from sphinx.config import Config
22
28
  from sphinx.ext import extlinks
29
+ from sphinx.util import console
23
30
  from sphinx.util import logging
24
31
 
25
32
  from . import version
26
33
  from openstackdocstheme import paths
27
34
 
28
- _series = None
29
- _project = None
35
+ _series: str | None = None
36
+ _project: str | None = None
30
37
  _giturl = 'https://opendev.org/{}/src/{}'
31
- _html_context_data = None
38
+ _html_context_data: dict[str, Any] | None = None
32
39
 
33
40
  logger = logging.getLogger(__name__)
34
41
 
35
42
 
36
- def _has_stable_branches():
43
+ def _has_stable_branches() -> bool:
37
44
  try:
38
45
  repo = dulwich.repo.Repo.discover()
39
- except dulwich.repo.NotGitRepository:
46
+ except dulwich.errors.NotGitRepository:
40
47
  return False
41
48
 
42
49
  refs = repo.get_refs()
43
- for ref in refs.keys():
44
- ref = ref.decode('utf-8')
50
+ for ref_bytes in refs.keys():
51
+ ref = ref_bytes.decode('utf-8')
45
52
  if ref.startswith('refs/remotes/origin/stable'):
46
53
  return True
47
54
 
48
55
  return False
49
56
 
50
57
 
51
- def _ref_sort_key(ref):
58
+ def _ref_sort_key(ref: str) -> str:
52
59
  # note(frickler): make sure to sort series like 2023.1 after zed
53
60
  if ref.startswith("2"):
54
61
  return "zzz" + ref
55
62
  return ref
56
63
 
57
64
 
58
- def _get_other_versions(app):
65
+ def _get_other_versions(app: application.Sphinx) -> list[str]:
59
66
  if not app.config.html_theme_options.get('show_other_versions', False):
60
67
  return []
61
68
 
62
- all_series = []
69
+ all_series: list[str] = []
63
70
  try:
64
71
  repo = dulwich.repo.Repo.discover()
65
- except dulwich.repo.NotGitRepository:
72
+ except dulwich.errors.NotGitRepository:
66
73
  return []
67
74
 
68
75
  refs = repo.get_refs()
69
- for ref in refs.keys():
70
- ref = ref.decode('utf-8')
76
+ for ref_b in refs.keys():
77
+ ref = ref_b.decode('utf-8')
71
78
  if ref.startswith('refs/remotes/origin/stable') or ref.startswith(
72
79
  'refs/remotes/origin/unmaintained'
73
80
  ):
@@ -101,7 +108,7 @@ def _get_other_versions(app):
101
108
  return interesting_series
102
109
 
103
110
 
104
- def _get_doc_path(app):
111
+ def _get_doc_path(app: application.Sphinx) -> str | None:
105
112
  # Handle 'doc/{docType}/source' paths
106
113
  doc_parts = os.path.abspath(app.srcdir).split(os.sep)[-3:]
107
114
  if doc_parts[0] == 'doc' and doc_parts[2] == 'source':
@@ -113,49 +120,67 @@ def _get_doc_path(app):
113
120
  return '/'.join(doc_parts)
114
121
 
115
122
  logger.info(
116
- "[openstackdocstheme] cannot identify project's root directory."
123
+ "%s",
124
+ console.colorize(
125
+ 'bold',
126
+ "[openstackdocstheme] cannot identify project's root directory",
127
+ ),
117
128
  )
118
- return
129
+ return None
119
130
 
120
131
 
121
- def _html_page_context(app, pagename, templatename, context, doctree):
132
+ def _html_page_context(
133
+ app: application.Sphinx,
134
+ pagename: str,
135
+ templatename: str,
136
+ context: dict[str, Any],
137
+ doctree: nodes.document | None,
138
+ ) -> None:
122
139
  global _html_context_data
123
140
  if _html_context_data is None:
124
141
  logger.debug('[openstackdocstheme] building html context')
125
142
 
126
143
  if app.config.repository_name is not None:
127
144
  logger.info(
128
- "[openstackdocstheme] "
129
- "the 'repository_name' config option has been deprecated and "
130
- "replaced by the 'openstackdocs_repo_name' option; support "
131
- "for the former will be dropped in a future release"
145
+ "%s; use 'openstackdocs_repo_name' instead. Support for "
146
+ "the old option will be dropped in a future release",
147
+ console.colorize(
148
+ 'bold',
149
+ "[openstackdocstheme] 'repository_name' is deprecated",
150
+ ),
132
151
  )
133
152
  app.config.openstackdocs_repo_name = app.config.repository_name
134
153
 
135
154
  if app.config.use_storyboard is not None:
136
155
  logger.info(
137
- "[openstackdocstheme] "
138
- "the 'use_storyboard' config option has been deprecated and "
139
- "replaced by the 'openstackdocs_use_storyboard' option; "
140
- "support for the former will be dropped in a future release"
156
+ "%s; use 'openstackdocs_use_storyboard' instead. Support for "
157
+ "the old option will be dropped in a future release",
158
+ console.colorize(
159
+ 'bold',
160
+ "[openstackdocstheme] 'use_storyboard' is deprecated",
161
+ ),
141
162
  )
142
163
  app.config.openstackdocs_use_storyboard = app.config.use_storyboard
143
164
 
144
165
  if app.config.bug_project is not None:
145
166
  logger.info(
146
- "[openstackdocstheme] "
147
- "the 'bug_project' config option has been deprecated and "
148
- "replaced by the 'openstackdocs_bug_project' option; support "
149
- "for the former will be dropped in a future release"
167
+ "%s; use 'openstackdocs_bug_project' "
168
+ "instead. Support for the old option will be dropped in a "
169
+ "future release",
170
+ console.colorize(
171
+ 'bold', "[openstackdocstheme] 'bug_project' is deprecated"
172
+ ),
150
173
  )
151
174
  app.config.openstackdocs_bug_project = app.config.bug_project
152
175
 
153
176
  if app.config.bug_tag is not None:
154
177
  logger.info(
155
- "[openstackdocstheme] "
156
- "the 'bug_tag' config option has been deprecated and "
157
- "replaced by the 'openstackdocs_bug_tag' option; support "
158
- "for the former will be dropped in a future release"
178
+ "%s; use 'openstackdocs_bug_tag' "
179
+ "instead. Support for the old option will be dropped in a "
180
+ "future release",
181
+ console.colorize(
182
+ 'bold', "[openstackdocstheme] 'bug_tag' is deprecated"
183
+ ),
159
184
  )
160
185
  app.config.openstackdocs_bug_project = app.config.bug_project
161
186
 
@@ -277,11 +302,11 @@ def _html_page_context(app, pagename, templatename, context, doctree):
277
302
  context['other_versions'] = _get_other_versions(app)
278
303
  logger.debug(
279
304
  '[openstackdocstheme] other_versions %s',
280
- context['other_versions'],
305
+ ', '.join(context['other_versions']),
281
306
  )
282
307
 
283
308
 
284
- def _get_series_name():
309
+ def _get_series_name() -> str:
285
310
  "Return string name of release series, or 'latest'"
286
311
  global _series
287
312
  if _series is None:
@@ -295,8 +320,11 @@ def _get_series_name():
295
320
  )
296
321
  except Exception:
297
322
  logger.info(
298
- '[openstackdocstheme] cannot find git top directory, '
299
- 'assuming "."'
323
+ '%s; assuming "."',
324
+ console.colorize(
325
+ 'bold',
326
+ '[openstackdocstheme] cannot find git top directory',
327
+ ),
300
328
  )
301
329
  git_root_dir = '.'
302
330
 
@@ -304,7 +332,13 @@ def _get_series_name():
304
332
  in_file = os.path.join(git_root_dir, '.gitreview')
305
333
  parsed = parser.read(in_file)
306
334
  if not parsed:
307
- logger.info('[openstackdocstheme] no %s found', in_file)
335
+ logger.info(
336
+ '%s: %s',
337
+ console.colorize(
338
+ 'bold', '[openstackdocstheme] file not found'
339
+ ),
340
+ in_file,
341
+ )
308
342
 
309
343
  try:
310
344
  branch = parser.get('gerrit', 'defaultbranch')
@@ -316,13 +350,11 @@ def _get_series_name():
316
350
  return _series
317
351
 
318
352
 
319
- def _setup_link_roles(app):
353
+ def _setup_link_roles(app: application.Sphinx) -> None:
320
354
  series = _get_series_name()
321
355
  for project_name in app.config.openstackdocs_projects:
322
- url = 'https://docs.openstack.org/{}/{}/%s'.format(
323
- project_name, series
324
- )
325
- role_name = '{}-doc'.format(project_name)
356
+ url = f'https://docs.openstack.org/{project_name}/{series}/%s'
357
+ role_name = f'{project_name}-doc'
326
358
  logger.debug(
327
359
  '[openstackdocstheme] adding role %s to link to %s',
328
360
  role_name,
@@ -334,18 +366,22 @@ def _setup_link_roles(app):
334
366
  app.add_role(role_name, role)
335
367
 
336
368
 
337
- def _find_setup_cfg(srcdir):
338
- """Find the 'setup.cfg' file, if it exists.
369
+ def _find_packaging_conf(
370
+ srcdir: str | os.PathLike[str], file: str
371
+ ) -> str | None:
372
+ """Find the packaging configuration file, if it exists.
373
+
374
+ Expected to be called with ``pyproject.toml`` or ``setup.cfg``.
339
375
 
340
- This assumes we're using 'doc/source' for documentation, but also allows
341
- for single level 'doc' paths.
376
+ This assumes we're using ``doc/source`` for documentation, but it also
377
+ allows for single level ``doc`` paths.
342
378
  """
343
379
  # TODO(stephenfin): Are we sure that this will always exist, e.g. for
344
380
  # an sdist or wheel? Perhaps we should check for 'PKG-INFO' or
345
381
  # 'METADATA' files, a la 'pbr.packaging._get_version_from_pkg_metadata'
346
382
  for path in [
347
- os.path.join(srcdir, os.pardir, 'setup.cfg'),
348
- os.path.join(srcdir, os.pardir, os.pardir, 'setup.cfg'),
383
+ os.path.join(srcdir, os.pardir, file),
384
+ os.path.join(srcdir, os.pardir, os.pardir, file),
349
385
  ]:
350
386
  if os.path.exists(path):
351
387
  return path
@@ -353,7 +389,7 @@ def _find_setup_cfg(srcdir):
353
389
  return None
354
390
 
355
391
 
356
- def _get_project_name(srcdir):
392
+ def _get_project_name(srcdir: str | os.PathLike[str]) -> str | None:
357
393
  """Return string name of project name, or None.
358
394
 
359
395
  This assumes every project is using 'pbr' and, therefore, the metadata can
@@ -363,15 +399,34 @@ def _get_project_name(srcdir):
363
399
  the package simply to build docs.
364
400
  """
365
401
  global _project
366
- if _project is None:
367
- parser = configparser.ConfigParser()
402
+ if _project is not None:
403
+ return _project
368
404
 
369
- path = _find_setup_cfg(srcdir)
370
- if not path or not parser.read(path):
371
- logger.info(
372
- '[openstackdocstheme] could not find a setup.cfg to extract '
373
- 'project name from'
374
- )
405
+ def _error(msg: str) -> None:
406
+ logger.info(
407
+ '%s: %s',
408
+ console.colorize(
409
+ 'bold',
410
+ '[openstackdocstheme] cannot determine project name',
411
+ ),
412
+ msg,
413
+ )
414
+
415
+ # prefer pyproject.toml
416
+ path = _find_packaging_conf(srcdir, 'pyproject.toml')
417
+ if path:
418
+ with open(path, 'rb') as f:
419
+ pyproject = tomllib.load(f)
420
+ project = pyproject.get('project', {}).get('name')
421
+ if project:
422
+ _project = project
423
+ return _project
424
+
425
+ path = _find_packaging_conf(srcdir, 'setup.cfg')
426
+ if path:
427
+ parser = configparser.ConfigParser()
428
+ if not parser.read(path):
429
+ _error('could not extract metadata from setup.cfg')
375
430
  return None
376
431
 
377
432
  try:
@@ -382,22 +437,28 @@ def _get_project_name(srcdir):
382
437
  if len(project.split()) == 1 and len(project) > 32:
383
438
  project = parser.get('metadata', 'summary')
384
439
  except configparser.Error:
385
- logger.info(
386
- '[openstackdocstheme] could not extract project metadata from '
387
- 'setup.cfg'
388
- )
440
+ _error('could not extract metadata from setup.cfg')
389
441
  return None
442
+
390
443
  _project = project
391
- return _project
444
+ return project
445
+
446
+ _error(
447
+ 'could not find a project.toml or setup.cfg to extract project '
448
+ 'name from'
449
+ )
450
+ return None
392
451
 
393
452
 
394
- def _config_inited(app, config):
453
+ def _config_inited(app: application.Sphinx, config: Config) -> None:
395
454
  if config.openstack_projects is not None:
396
455
  logger.info(
397
- "[openstackdocstheme] "
398
- "the 'openstack_projects' config option has been deprecated and "
399
- "replaced by the 'openstackdocs_projects' option; support "
400
- "for the former will be dropped in a future release"
456
+ "%s; use 'openstackdocs_projects' instead. "
457
+ "Support for the old option will be dropped in a future release",
458
+ console.colorize(
459
+ 'bold',
460
+ "[openstackdocstheme] 'openstack_projects' is deprecated",
461
+ ),
401
462
  )
402
463
  config.openstackdocs_projects = config.openstack_projects
403
464
 
@@ -411,10 +472,13 @@ def _config_inited(app, config):
411
472
 
412
473
  if config.project and project_name:
413
474
  logger.info(
414
- "[openstackdocstheme] "
415
- "overriding configured project name (%s) with name extracted "
416
- "from the package (%s); you can disable this behavior with "
417
- "the 'openstackdocs_auto_name' option",
475
+ "%s: %s -> %s (extracted from the "
476
+ "package); you can disable this behavior with the "
477
+ "'openstackdocs_auto_name' option",
478
+ console.colorize(
479
+ 'bold',
480
+ '[openstackdocstheme] overriding configured project name',
481
+ ),
418
482
  config.project,
419
483
  project_name,
420
484
  )
@@ -439,8 +503,9 @@ def _config_inited(app, config):
439
503
  doc_parts = os.path.abspath(app.srcdir).split(os.sep)[-2:]
440
504
  if doc_parts[0] in ('api-guide', 'api-ref', 'releasenotes'):
441
505
  logger.debug(
442
- f'[openstackdocstheme] auto-versioning disabled (doc name '
443
- f'contains {doc_parts[0]}'
506
+ '[openstackdocstheme] auto-versioning disabled (doc name '
507
+ 'contains %s)',
508
+ doc_parts[0],
444
509
  )
445
510
  auto_version = False
446
511
  else:
@@ -466,9 +531,13 @@ def _config_inited(app, config):
466
531
  config.release = project_version
467
532
 
468
533
 
469
- def _builder_inited(app):
534
+ def _builder_inited(app: application.Sphinx) -> None:
470
535
  theme_dir = paths.get_html_theme_path()
471
- logger.info('[openstackdocstheme] using theme from %s', theme_dir)
536
+ logger.info(
537
+ '%s %s',
538
+ console.colorize('bold', '[openstackdocstheme] using theme from'),
539
+ theme_dir,
540
+ )
472
541
 
473
542
  _setup_link_roles(app)
474
543
 
@@ -507,9 +576,10 @@ def _builder_inited(app):
507
576
  app.config.latex_elements = latex_elements
508
577
 
509
578
 
510
- def setup(app):
579
+ def setup(app: application.Sphinx) -> dict[str, Any]:
511
580
  logger.info(
512
- '[openstackdocstheme] version: %s',
581
+ '%s %s',
582
+ console.colorize('bold', '[openstackdocstheme] version:'),
513
583
  version.version_info.version_string(),
514
584
  )
515
585
  logger.debug('[openstackdocstheme] connecting events')
@@ -15,8 +15,10 @@ import os
15
15
  import os.path
16
16
  import subprocess
17
17
  import time
18
+ from typing import Any
18
19
 
19
- import sphinx
20
+ from docutils import nodes
21
+ from sphinx import application
20
22
  from sphinx.util import logging
21
23
 
22
24
  from . import version
@@ -24,10 +26,12 @@ from . import version
24
26
  LOG = logging.getLogger(__name__)
25
27
 
26
28
  _timeint = int(os.environ.get('SOURCE_DATE_EPOCH', time.time()))
27
- _default_last_updated = datetime.datetime.utcfromtimestamp(_timeint)
29
+ _default_last_updated = datetime.datetime.fromtimestamp(
30
+ _timeint, tz=datetime.UTC
31
+ ).replace(tzinfo=None)
28
32
 
29
33
 
30
- def _get_last_updated_file(src_file):
34
+ def _get_last_updated_file(src_file: str) -> datetime.datetime | None:
31
35
  if not os.path.exists(src_file):
32
36
  return None
33
37
  try:
@@ -72,22 +76,17 @@ def _get_last_updated_file(src_file):
72
76
  return None
73
77
 
74
78
 
75
- def _get_last_updated(app, pagename):
79
+ def _get_last_updated(
80
+ app: application.Sphinx, pagename: str
81
+ ) -> datetime.datetime:
76
82
  last_updated = None
77
83
  full_src_file = app.builder.env.doc2path(pagename)
78
84
 
79
- candidates = []
85
+ candidates: list[str] = []
80
86
 
81
87
  # Strip the prefix from the filename so the git command recognizes
82
88
  # the file as part of the current repository.
83
- # NOTE(sean-k-mooney): on python 3.9 we clamp sphinx to <8
84
- # app.builder.env.srcdir is a string on py39
85
- if sphinx.version_info >= (8, 0):
86
- src_file = str(full_src_file.relative_to(app.builder.env.srcdir))
87
- else: # Sphinx < 8.0
88
- src_file = full_src_file[len(str(app.builder.env.srcdir)) :].lstrip(
89
- '/'
90
- )
89
+ src_file = str(full_src_file.relative_to(app.builder.env.srcdir))
91
90
  candidates.append(src_file)
92
91
 
93
92
  if not os.path.exists(src_file):
@@ -108,7 +107,7 @@ def _get_last_updated(app, pagename):
108
107
  return last_updated
109
108
 
110
109
  if pagename not in ('genindex', 'search'):
111
- LOG.info(
110
+ LOG.debug(
112
111
  '[openstackdocstheme] could not determine last_updated for %r',
113
112
  pagename,
114
113
  )
@@ -116,14 +115,22 @@ def _get_last_updated(app, pagename):
116
115
  return _default_last_updated
117
116
 
118
117
 
119
- def html_page_context(app, pagename, templatename, context, doctree):
118
+ def html_page_context(
119
+ app: application.Sphinx,
120
+ pagename: str,
121
+ templatename: str,
122
+ context: dict[str, Any],
123
+ doctree: nodes.document | None,
124
+ ) -> None:
120
125
  # Use the last modified date from git instead of applying a single
121
126
  # value to the entire site.
122
127
  context['last_updated'] = _get_last_updated(app, pagename)
123
128
 
124
129
 
125
- def setup(app):
126
- LOG.info('[openstackdocstheme] connecting html-page-context event handler')
130
+ def setup(app: application.Sphinx) -> dict[str, Any]:
131
+ LOG.debug(
132
+ '[openstackdocstheme] connecting html-page-context event handler'
133
+ )
127
134
  app.connect('html-page-context', html_page_context)
128
135
  return {
129
136
  'parallel_read_safe': True,
@@ -15,28 +15,28 @@
15
15
  import os.path
16
16
 
17
17
 
18
- def get_pkg_path():
18
+ def get_pkg_path() -> str:
19
19
  return os.path.abspath(os.path.dirname(__file__))
20
20
 
21
21
 
22
- def get_html_theme_path():
22
+ def get_html_theme_path() -> str:
23
23
  """Return the directory containing HTML theme for local builds."""
24
24
  return os.path.join(get_pkg_path(), 'theme')
25
25
 
26
26
 
27
- def get_pdf_theme_path(theme='openstackdocs'):
27
+ def get_pdf_theme_path(theme: str = 'openstackdocs') -> str:
28
28
  """Return the directory containing PDF theme for local builds."""
29
29
  args = ['theme', theme + '_pdf', 'pdftheme']
30
30
  return os.path.join(get_pkg_path(), *args)
31
31
 
32
32
 
33
- def get_theme_logo_path(theme='openstackdocs'):
33
+ def get_theme_logo_path(theme: str = 'openstackdocs') -> str:
34
34
  """Return the directory containing theme logo for local builds."""
35
35
  args = ['theme', theme + '_pdf', 'logo-full.png']
36
36
  return os.path.join(get_pkg_path(), *args)
37
37
 
38
38
 
39
39
  # This function is for compatibility with previous releases.
40
- def get_openstack_logo_path():
40
+ def get_openstack_logo_path() -> str:
41
41
  """Return the directory containing OpenStack logo for local builds."""
42
42
  return get_theme_logo_path('openstackdocs')
@@ -12,6 +12,8 @@
12
12
  # License for the specific language governing permissions and limitations
13
13
  # under the License.
14
14
 
15
- import pbr.version
15
+ from pbr import version as pbr_version
16
16
 
17
- version_info = pbr.version.VersionInfo('openstackdocstheme')
17
+ version_info: pbr_version.VersionInfo = pbr_version.VersionInfo(
18
+ 'openstackdocstheme'
19
+ )