mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
Use html_extra_template_renderer to replace the current robots.txt rendering script
This commit is contained in:
+5
-1
@@ -161,7 +161,7 @@ html_js_files = ["js/toggle.js"]
|
||||
# Add any extra paths that contain custom files (such as robots.txt or
|
||||
# .htaccess) here, relative to this directory. These files are copied
|
||||
# directly to the root of the documentation.
|
||||
html_extra_path = ["_static/css", "_static/robots.txt"]
|
||||
html_extra_path = ["_static/css"]
|
||||
|
||||
# List of templates of static files to be included in the HTML output.
|
||||
# Keys represent paths to input files and values are dicts containing:
|
||||
@@ -170,6 +170,10 @@ html_extra_path = ["_static/css", "_static/robots.txt"]
|
||||
# All paths must be absolute.
|
||||
# Rendered templates are automatically added to html_extra_path setting.
|
||||
html_extra_templates = {
|
||||
os.path.join(ROOT_PATH, "robots.txt.template"): {
|
||||
'target': os.path.join(ROOT_PATH, "_static/robots.txt"),
|
||||
'context': {'LATEST_VERSION': version},
|
||||
}
|
||||
}
|
||||
|
||||
# If not '', a 'Last updated on:' timestamp is inserted at every page bottom,
|
||||
|
||||
Reference in New Issue
Block a user