mirror of https://github.com/crossplane/docs.git
Merge pull request #3 from thephred/add-docs-latest
Add a /doc/latest and fix issues with redirecting.
This commit is contained in:
commit
b5ffffccec
|
@ -4,4 +4,4 @@
|
||||||
{% assign forumLink = "https://groups.google.com/forum/#!forum/crossplane-dev" %}
|
{% assign forumLink = "https://groups.google.com/forum/#!forum/crossplane-dev" %}
|
||||||
{% assign blogLink = "https://blog.upbound.io/" %}
|
{% assign blogLink = "https://blog.upbound.io/" %}
|
||||||
{% assign communityMeetingLink = "https://github.com/crossplaneio/crossplane/#community-meeting" %}
|
{% assign communityMeetingLink = "https://github.com/crossplaneio/crossplane/#community-meeting" %}
|
||||||
{% assign latestDocs = site.data.versions[0].path %}
|
{% assign latestDocs = site.data.versions[0].path | append: '/' %}
|
||||||
|
|
|
@ -31,7 +31,7 @@
|
||||||
<div class="versions{% if currentVersion == latestVersion %} latest{% endif %}">
|
<div class="versions{% if currentVersion == latestVersion %} latest{% endif %}">
|
||||||
<select onchange="window.location.href = this.value">
|
<select onchange="window.location.href = this.value">
|
||||||
{% for ver in site.data.versions %}
|
{% for ver in site.data.versions %}
|
||||||
<option {% if ver.version == currentVersion %}selected{% endif %} value="{{ver.path}}">Crossplane {{ ver.version }}</option>
|
<option {% if ver.version == currentVersion %}selected{% endif %} value="{{ver.path | append: '/'}}">Crossplane {{ ver.version }}</option>
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
</select>
|
</select>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -0,0 +1,18 @@
|
||||||
|
---
|
||||||
|
layout: false
|
||||||
|
---
|
||||||
|
{% include values.inc %}
|
||||||
|
<!DOCTYPE html>
|
||||||
|
<html lang="en">
|
||||||
|
<head>
|
||||||
|
<meta charset="UTF-8">
|
||||||
|
<title>Redirecting...</title>
|
||||||
|
<link rel="canonical" href="{{ latestDocs }}"/>
|
||||||
|
<meta http-equiv="refresh" content="0;url={{ latestDocs }}" />
|
||||||
|
</head>
|
||||||
|
<body>
|
||||||
|
<h1>Redirecting...</h1>
|
||||||
|
<a href="{{ latestDocs }}">Click here if you are not redirected.<a>
|
||||||
|
<script>location='{{ latestDocs }}'</script>
|
||||||
|
</body>
|
||||||
|
</html>
|
Loading…
Reference in New Issue