diff options
author | Googler <noreply@google.com> | 2017-12-04 02:19:03 -0800 |
---|---|---|
committer | Copybara-Service <copybara-piper@google.com> | 2017-12-04 02:21:10 -0800 |
commit | 4739eb5918f985a0237544f103e4c0eb540fbed8 (patch) | |
tree | e6b38b9976a3444ee2ef7a34647489cc7a00851b /site/_includes | |
parent | 57daf52dc43bc54fbfe8d00ca3d7ac88ab34baea (diff) |
Remove redirects for domains be.bazel.build and cr.bazel.build from the source for docs.bazel.build (because those subdomains don't resolve here; they resolve to bazel.build, which has the redirects for them)
RELNOTES: Remove redirects for domains be.bazel.build and cr.bazel.build from the source for docs.bazel.build (because those subdomains don't resolve here; they resolve to bazel.build, which has the redirects for them)
PiperOrigin-RevId: 177787458
Diffstat (limited to 'site/_includes')
-rw-r--r-- | site/_includes/head.html | 24 |
1 files changed, 0 insertions, 24 deletions
diff --git a/site/_includes/head.html b/site/_includes/head.html index 8c844d86bd..ceef1ccfef 100644 --- a/site/_includes/head.html +++ b/site/_includes/head.html @@ -4,30 +4,6 @@ <meta name="viewport" content="width=device-width, initial-scale=1"> <title>{{ page.title }} - Bazel</title> - <script> - var current_url = window.location.href; - - // Do a shortcut so that be.bazel.build redirect to the build encyclopedia - var be_url = new RegExp("^https?://be(\.bazel.build)?/?"); - if (be_url.test(current_url)) { - window.location.replace(current_url.replace(be_url, "https://docs.bazel.build/be/overview.html")); - } - var be_url = new RegExp("^https?://be(\.bazel.build)?/([a-zA-Z0-9_-]+)([/#](.*))?"); - if (be_url.test(current_url)) { - window.location.replace(current_url.replace(be_url, "https://docs.bazel.build/be/$2.html#$4")); - } - // And a short to code reviews - var cr_url = new RegExp("^https?://cr(\.bazel.build)?/([0-9]+)") - if (cr_url.test(current_url)) { - window.location.replace(current_url.replace(cr_url, "https://bazel-review.googlesource.com/c/$2")); - } - // Code review dashboard - var cr_url = new RegExp("^https?://cr(\.bazel.build)?/?") - if (cr_url.test(current_url)) { - window.location.replace(current_url.replace(cr_url, "https://bazel-review.googlesource.com/")); - } - </script> - <link rel="canonical" href="{{ page.url | replace:'index.html','' | prepend: site_root }}"> <!-- Webfont --> |