Skip to content

Commit 0b387d6

Browse files
committed
Merge branch '99-create-redirects-for-deleted-content' into 'master'
Resolve "create redirects for deleted content" Closes divio#99 See merge request divio/cloud/divio-cloud-docs!117
2 parents a3b0d78 + c44f065 commit 0b387d6

4 files changed

Lines changed: 25 additions & 3 deletions

File tree

CHANGELOG.rst

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,6 @@ Changelog
22
=========
33

44
x.x.x (x-x-x)
5-
-------------------
5+
-------------------
6+
7+
* Configured redirects for broken links

conf.py

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@
4141
"sphinx_inline_tabs",
4242
"sphinx_click",
4343
"notfound.extension",
44+
"sphinx_reredirects",
4445
]
4546

4647
if "spelling" in sys.argv:
@@ -130,3 +131,18 @@
130131
todo_include_todos = True
131132
todo_link_only = True
132133
todo_emit_warnings = False
134+
135+
#
136+
# -- Redirects for broken links -----------------------------------------------
137+
#
138+
139+
# The following represents a valid redirect pattern example for renaming/deleting a file
140+
# inside the how-to folder called configure-settings.rst to django-configure-settings.rst
141+
# that must be included inside redirects dictionary below.
142+
143+
# Redirect pattern:
144+
# "how-to/configure-settings/index.html": "../django-configure-settings",
145+
146+
redirects = {
147+
"how-to/configure-settings/index.html": "../django-configure-settings",
148+
}

requirements.in

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,3 +10,4 @@ sphinx-click
1010
sphinx-inline-tabs
1111
sphinx-rtd-theme
1212
pyenchant
13+
sphinx-reredirects

requirements.txt

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ attrs==21.2.0
1010
# via divio-cli
1111
babel==2.9.1
1212
# via sphinx
13-
backports.zoneinfo==0.2.1
13+
backports-zoneinfo==0.2.1
1414
# via
1515
# divio-cli
1616
# tzlocal
@@ -41,7 +41,7 @@ docutils==0.17.1
4141
# sphinx
4242
# sphinx-click
4343
# sphinx-rtd-theme
44-
https://github.com/divio/docs-theme/archive/master.zip#egg=furo
44+
furo @ https://github.com/divio/docs-theme/archive/master.zip
4545
# via -r requirements.in
4646
idna==3.2
4747
# via
@@ -103,6 +103,7 @@ sphinx==4.2.0
103103
# sphinx-autobuild
104104
# sphinx-click
105105
# sphinx-inline-tabs
106+
# sphinx-reredirects
106107
# sphinx-rtd-theme
107108
# sphinxcontrib-spelling
108109
sphinx-autobuild==2021.3.14
@@ -113,6 +114,8 @@ sphinx-inline-tabs==2021.8.17b10
113114
# via -r requirements.in
114115
sphinx-notfound-page==0.7.1
115116
# via -r requirements.in
117+
sphinx-reredirects==0.0.1
118+
# via -r requirements.in
116119
sphinx-rtd-theme==1.0.0
117120
# via -r requirements.in
118121
sphinxcontrib-applehelp==1.0.2

0 commit comments

Comments
 (0)