conf.py 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289
  1. # -*- coding: utf-8 -*-
  2. #
  3. # GeoServer documentation build configuration file, created by
  4. # sphinx-quickstart on Tue Oct 28 10:01:09 2008.
  5. #
  6. # This file is execfile()d with the current directory set to its containing dir.
  7. #
  8. # The contents of this file are pickled, so don't put values in the namespace
  9. # that aren't pickleable (module imports are okay, they're removed automatically).
  10. #
  11. # All configuration values have a default value; values that are commented out
  12. # serve to show the default value.
  13. import sys, os, string
  14. import datetime
  15. # If your extensions are in another directory, add it here. If the directory
  16. # is relative to the documentation root, use os.path.abspath to make it
  17. # absolute, like shown here.
  18. #sys.path.append(os.path.abspath('some/directory'))
  19. now = datetime.datetime.now()
  20. # General configuration
  21. # ---------------------
  22. # Add any Sphinx extension module names here, as strings. They can be extensions
  23. # coming with Sphinx (named 'sphinx.ext.*') or your custom ones.
  24. extensions = ['sphinx.ext.todo', 'sphinx.ext.extlinks']
  25. #todo_include_todos = True
  26. # Add any paths that contain templates here, relative to this directory.
  27. #templates_path = ['../../theme/_templates']
  28. # The suffix of source filenames.
  29. source_suffix = '.rst'
  30. # The master toctree document.
  31. master_doc = 'index'
  32. # General substitutions.
  33. project = u'GeoServer'
  34. manual = u'User Manual'
  35. copyright = u'{}, Open Source Geospatial Foundation'.format(now.year)
  36. # The default replacements for |version| and |release|, also used in various
  37. # other places throughout the built documents.
  38. #
  39. # The replacement |version| provides short X.Y version.
  40. version = '2.26'
  41. # The relacement |release| provides the full version, including alpha/beta/rc tags.
  42. # sphinx-build -D release=${project.version} overrides release configuration
  43. # but only after conf.py has been used...
  44. # check environmental variable to see if ant build.xml passed in project.version
  45. project_version = os.getenv("project.version")
  46. if project_version == None:
  47. release = '2.26-SNAPSHOT'
  48. else:
  49. release = project_version
  50. # Used in build and documentation links
  51. # branch = version+'.x'
  52. branch = 'main'
  53. # Users don't need to see the "SNAPSHOT" notation when it's there
  54. if release.find('SNAPSHOT') != -1:
  55. tags.add('snapshot')
  56. download = version+'.x'
  57. release = '2.26.x'
  58. latest = '-latest'
  59. download_release = 'https://build.geoserver.org/geoserver/'+branch+'/geoserver-'+version+'.x-latest-%s.zip'
  60. download_extension = 'https://build.geoserver.org/geoserver/'+branch+'/ext-latest/geoserver-'+version+'-SNAPSHOT-%s-plugin.zip'
  61. download_community = 'https://build.geoserver.org/geoserver/'+branch+'/community-latest/geoserver-'+version+'-SNAPSHOT-%s-plugin.zip'
  62. else:
  63. download = release
  64. latest = ''
  65. download_release = 'http://sourceforge.net/projects/geoserver/files/GeoServer/'+release+'/geoserver-'+release+'-%s.zip'
  66. download_extension = 'https://sourceforge.net/projects/geoserver/files/GeoServer/'+release+'/extensions/geoserver-'+release+'-%s-plugin.zip'
  67. download_community = 'https://build.geoserver.org/geoserver/'+branch+'/community-latest/geoserver-'+version+'.x-SNAPSHOT-%s-plugin.zip'
  68. # There are two options for replacing |today|: either, you set today to some
  69. # non-false value, then it is used:
  70. #today = ''
  71. # Else, today_fmt is used as the format for a strftime call.
  72. today_fmt = '%B %d, %Y'
  73. # List of documents that shouldn't be included in the build.
  74. #unused_docs = []
  75. # A list of glob-style patterns [1] that should be excluded when looking for source files.
  76. # They are matched against the source file names relative to the source directory,
  77. # using slashes as directory separators on all platforms.
  78. exclude_patterns = [
  79. '**/symbolizers/include/*.rst'
  80. ]
  81. # List of directories, relative to source directories, that shouldn't be searched
  82. # for source files.
  83. exclude_trees = []
  84. # The reST default role (used for this markup: `text`) to use for all documents.
  85. #default_role = None
  86. # If true, '()' will be appended to :func: etc. cross-reference text.
  87. #add_function_parentheses = True
  88. # If true, the current module name will be prepended to all description
  89. # unit titles (such as .. function::).
  90. #add_module_names = True
  91. # If true, sectionauthor and moduleauthor directives will be shown in the
  92. # output. They are ignored by default.
  93. #show_authors = False
  94. # The name of the Pygments (syntax highlighting) style to use.
  95. pygments_style = 'sphinx'
  96. # Options for extlinks
  97. #
  98. # :website:`license <License>`
  99. # :geos:`1234`
  100. # :wiki:`Proposals`
  101. # -----------------------------------
  102. extlinks = {
  103. 'wiki': ('https://github.com/geoserver/geoserver/wiki/%s', None),
  104. 'website': ('http://geoserver.org/%s', None),
  105. 'user': ('http://docs.geoserver.org/'+branch+'/en/user/%s', None),
  106. 'developer': ('http://docs.geoserver.org/latest/en/developer/%s', None),
  107. 'docguide': ('http://docs.geoserver.org/latest/en/docguide/%s', None),
  108. 'geos': ('https://osgeo-org.atlassian.net/browse/GEOS-%s','GEOS-%s'),
  109. 'geot': ('https://osgeo-org.atlassian.net/browse/GEOT-%s','GEOT-%s'),
  110. 'api': ('http://docs.geoserver.org/latest/en/api/#1.0.0/%s', None),
  111. 'geotools': ('https://docs.geotools.org/latest/userguide/%s', None),
  112. 'download_release': (download_release,'geoserver-'+download+latest+'-%s.zip'),
  113. 'download_extension': (download_extension,'geoserver-'+download+'-%s-plugin.zip'),
  114. 'download_community': (download_community,'geoserver-'+download+'-%s-plugin.zip')
  115. }
  116. # Common substitutions
  117. rst_epilog = "\n" \
  118. ".. |install_directory_winXP| replace:: :file:`C:\Program Files\\\\GeoServer "+release+"`\n" \
  119. ".. |install_directory_win| replace:: :file:`C:\\\\Program Files (x86)\\\\GeoServer "+release+"`\n" \
  120. ".. |install_directory_linux| replace:: :file:`/var/lib/tomcat7/webapps/geoserver`\n" \
  121. ".. |install_directory_mac| replace:: :file:`/Applications`\n" \
  122. ".. |data_directory_winXP| replace:: :file:`C:\Program Files\\\\GeoServer "+release+"\\\\data_dir`\n" \
  123. ".. |data_directory_win| replace:: :file:`C:\\\\Program Files (x86)\\\\GeoServer "+release+"\\\\data_dir`\n" \
  124. ".. |data_directory_linux| replace:: :file:`/var/lib/tomcat7/webapps/geoserver/data`\n" \
  125. ".. |data_directory_mac| replace:: :file:`/Applications/GeoServer.app/Contents/Resources/Java/data_dir`"
  126. # Options for HTML output
  127. # -----------------------
  128. html_theme = 'geoserver'
  129. html_theme_path = ['../../themes']
  130. if os.environ.get('HTML_THEME_PATH'):
  131. html_theme_path.append(os.environ.get('HTML_THEME_PATH'))
  132. # The style sheet to use for HTML and HTML Help pages. A file of that name
  133. # must exist either in Sphinx' static/ path, or in one of the custom paths
  134. # given in html_static_path.
  135. #html_style = 'default.css'
  136. # The name for this set of Sphinx documents. If None, it defaults to
  137. # "<project> v<release> documentation".
  138. html_title = project + " " + release + " " + manual
  139. # A shorter title for the navigation bar. Default is the same as html_title.
  140. #html_short_title = None
  141. # The name of an image file (relative to this directory) to place at the top
  142. # of the sidebar.
  143. #html_logo = None
  144. # The name of an image file (within the static path) to use as favicon of the
  145. # docs. This file should be a Windows icon file (.ico) being 16x16 or 32x32
  146. # pixels large.
  147. html_favicon = '../../themes/geoserver/static/geoserver.ico'
  148. # Add any paths that contain custom static files (such as style sheets) here,
  149. # relative to this directory. They are copied after the builtin static files,
  150. # so a file named "default.css" will overwrite the builtin "default.css".
  151. #html_static_path = ['../../theme/_static']
  152. # If not '', a 'Last updated on:' timestamp is inserted at every page bottom,
  153. # using the given strftime format.
  154. html_last_updated_fmt = '%b %d, %Y'
  155. # If true, SmartyPants will be used to convert quotes and dashes to
  156. # typographically correct entities.
  157. #html_use_smartypants = True
  158. # Custom sidebar templates, maps document names to template names.
  159. #html_sidebars = {}
  160. # Additional templates that should be rendered to pages, maps page names to
  161. # template names.
  162. #html_additional_pages = {}
  163. # If false, no module index is generated.
  164. html_domain_indices = False
  165. # If false, no index is generated.
  166. html_use_index = False
  167. # If true, the index is split into individual pages for each letter.
  168. #html_split_index = False
  169. # If true, the sphinx sources are included in the HTML build as _sources/<name>.
  170. html_copy_source = False
  171. # If true, links to the page source are added to each page.
  172. html_show_sourcelink = False
  173. # If true, an OpenSearch description file will be output, and all pages will
  174. # contain a <link> tag referring to it. The value of this option must be the
  175. # base URL from which the finished HTML is served.
  176. #html_use_opensearch = ''
  177. # If nonempty, this is the file name suffix for HTML files (e.g. ".xhtml").
  178. #html_file_suffix = ''
  179. # Output file base name for HTML help builder.
  180. htmlhelp_basename = 'GeoServerUserManual'
  181. html_context = {
  182. 'display_github': True,
  183. 'github_user': 'geoserver',
  184. 'github_repo': 'geoserver',
  185. 'github_version': 'main',
  186. 'conf_py_path': 'doc/en/user/source',
  187. 'manual': manual,
  188. }
  189. # Options for LaTeX output
  190. # ------------------------
  191. # The paper size ('letter' or 'a4').
  192. #latex_paper_size = 'letter'
  193. # The font size ('10pt', '11pt' or '12pt').
  194. #latex_font_size = '10pt'
  195. # Grouping the document tree into LaTeX files. List of tuples
  196. # (source start file, target name, title, author, document class [howto/manual]).
  197. latex_documents = [
  198. ('index', 'GeoServerUserManual.tex', u'GeoServer User Manual',
  199. u'GeoServer', 'manual'),
  200. ]
  201. # The name of an image file (relative to this directory) to place at the top of
  202. # the title page.
  203. latex_logo = '../../themes/geoserver/static/GeoServer_500.png'
  204. # For "manual" documents, if this is true, then toplevel headings are parts,
  205. # not chapters.
  206. #latex_use_parts = False
  207. # Additional stuff for the LaTeX preamble.
  208. latex_elements = {
  209. 'fontpkg': '\\usepackage{palatino}',
  210. 'fncychap': '\\usepackage[Sonny]{fncychap}',
  211. 'preamble': #"""\\usepackage[parfill]{parskip}
  212. """
  213. \\hypersetup{
  214. colorlinks = true,
  215. linkcolor = [rgb]{0,0.46,0.63},
  216. anchorcolor = [rgb]{0,0.46,0.63},
  217. citecolor = blue,
  218. filecolor = [rgb]{0,0.46,0.63},
  219. pagecolor = [rgb]{0,0.46,0.63},
  220. urlcolor = [rgb]{0,0.46,0.63}
  221. }
  222. """
  223. }
  224. # Documents to append as an appendix to all manuals.
  225. #latex_appendices = []
  226. # If false, no module index is generated.
  227. #latex_use_modindex = True