Skip to content

Commit

Permalink
Add redirects for registry links
Browse files Browse the repository at this point in the history
Co-authored-by: Eric Huss <eric@huss.org>
  • Loading branch information
arlosi and ehuss authored Dec 15, 2022
1 parent a71b17d commit 9231df2
Showing 1 changed file with 25 additions and 0 deletions.
25 changes: 25 additions & 0 deletions src/doc/src/reference/registries.md
Original file line number Diff line number Diff line change
Expand Up @@ -99,3 +99,28 @@ token = "854DvwSlUwEHtIo3kWy6x7UCPKHfzCmy"
[`cargo package`]: ../commands/cargo-package.md
[`cargo login`]: ../commands/cargo-login.md
[config]: config.md

<script>
(function() {
var fragments = {
"#running-a-registry": "running-a-registry.html",
"#index-format": "registry-index.html",
"#web-api": "registry-web-api.html",
"#publish": "registry-web-api.html#publish",
"#yank": "registry-web-api.html#yank",
"#unyank": "registry-web-api.html#unyank",
"#owners": "registry-web-api.html#owners",
"#owners-list": "registry-web-api.html#owners-list",
"#owners-add": "registry-web-api.html#owners-add",
"#owners-remove": "registry-web-api.html#owners-remove",
"#search": "registry-web-api.html#search",
"#login": "registry-web-api.html#login",
};
var target = fragments[window.location.hash];
if (target) {
var url = window.location.toString();
var base = url.substring(0, url.lastIndexOf('/'));
window.location.replace(base + "/" + target);
}
})();
</script>

0 comments on commit 9231df2

Please sign in to comment.