-
Notifications
You must be signed in to change notification settings - Fork 537
Add redirects for relocated docs #10221
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -62,6 +62,7 @@ | |
"myst_parser", | ||
"sphinx_design", | ||
"sphinx_gallery.gen_gallery", | ||
"sphinx_reredirects", | ||
] | ||
|
||
if not FBCODE: | ||
|
@@ -195,6 +196,24 @@ | |
"torch": ("https://pytorch.org/docs/stable/", None), | ||
} | ||
|
||
# Redirects for moved pages | ||
redirects = { | ||
"getting-started-setup": "getting-started.html", | ||
"export-overview": "using-executorch-export.html", | ||
"runtime-build-and-cross-compilation": "using-executorch-building-from-source.html", | ||
"tutorials/export-to-executorch-tutorial": "../using-executorch-export.html", | ||
"running-a-model-cpp-tutorial": "using-executorch-cpp.html", | ||
"build-run-vulkan": "backends-vulkan.html", | ||
"executorch-arm-delegate-tutorial": "backends-arm-ethos-u.html", | ||
"build-run-coreml": "backends-coreml.html", | ||
"build-run-mediatek-backend": "backends-mediatek.html", | ||
"build-run-mps": "backends-mps.html", | ||
"build-run-qualcomm-ai-engine-direct-backend": "backends-qualcomm.html", | ||
"build-run-xtensa": "backends-cadence.html", | ||
"apple-runtime": "using-executorch-ios.html", | ||
Comment on lines
+208
to
+213
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Not sure we have any of these left There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Yeah, the goal of this change is to make these old links point to the new pages. That way any external links (and SEO) will continue to work. I.e. if some other website links to the old "/build-run-coreml.html" page, it will auto-redirect to"/backends-coreml.html" and not be broken. |
||
"tutorials/devtools-integration-tutorial": "../using-executorch-troubleshooting.html", | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I don't think this is correct. original path is correct, it will not show up until running There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @Gasoonjia Can you explain more what you mean? I did manually test all of the redirected links and they worked as expected. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. yes your redirection is working, but the page you redirect to is not the one we need. this is the one you redirected to: https://pytorch.org/executorch/0.6/using-executorch-troubleshooting.html There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Sure. Feel free to update the redirect link if you prefer that page. |
||
} | ||
|
||
# Custom directives defintions to create cards on main landing page | ||
|
||
from custom_directives import ( # type: ignore[import-not-found] | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Perhaps a simple find\replace would work as well?