Skip to content

Commit

Permalink
Added robots.txt to disallow older version docs.
Browse files Browse the repository at this point in the history
  • Loading branch information
cgkoutzigiannis committed Sep 11, 2024
1 parent bd0a592 commit ef4991c
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 0 deletions.
2 changes: 2 additions & 0 deletions changes/2708.misc.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
Add a robots.txt to disallow search engines to show unstable docs versions.
Created a new folder for it and configured Sphinx to find it.
2 changes: 2 additions & 0 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -372,3 +372,5 @@ def autodoc_process_signature(

# If this is True, todolist produce output without file path and line, The default is False.
# todo_link_only = False

html_extra_path = ["extra"]
4 changes: 4 additions & 0 deletions docs/extra/robots.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
User-agent: *
Disallow: /en/latest/
Disallow: /en/v*
Allow: /en/stable/

0 comments on commit ef4991c

Please sign in to comment.