diff --git a/docs/Gemfile b/docs/Gemfile index 37f5eaa4..bcd3be7d 100644 --- a/docs/Gemfile +++ b/docs/Gemfile @@ -1,2 +1,3 @@ source 'https://rubygems.org' gem 'github-pages', group: :jekyll_plugins +gem 'jekyll-redirect-from' diff --git a/docs/Gemfile.lock b/docs/Gemfile.lock index a8c1c4a1..feb6c6f6 100644 --- a/docs/Gemfile.lock +++ b/docs/Gemfile.lock @@ -245,6 +245,7 @@ PLATFORMS DEPENDENCIES github-pages + jekyll-redirect-from BUNDLED WITH 1.16.1 diff --git a/docs/_config.yaml b/docs/_config.yaml index 0333b947..49bf96c2 100644 --- a/docs/_config.yaml +++ b/docs/_config.yaml @@ -1,2 +1,4 @@ theme: jekyll-theme-minimal exclude: [ruby-bundle] +plugins: + - jekyll-redirect-from diff --git a/docs/_data/index.yaml b/docs/_data/index.yaml index f55f1548..4070d1e4 100644 --- a/docs/_data/index.yaml +++ b/docs/_data/index.yaml @@ -6,7 +6,7 @@ sections: - title: For Users docs: - title: Getting Started - url: getting-started + url: / - title: ODrive Tool url: odrivetool - title: Parameters & Commands diff --git a/docs/_layouts/default.html b/docs/_layouts/default.html index 0d862ce8..99fd9256 100644 --- a/docs/_layouts/default.html +++ b/docs/_layouts/default.html @@ -55,7 +55,8 @@
- {% assign filename = page.url | replace_first: '/', '' | replace: '.html', '.md' %} + {% assign filename = page.url | replace_first: '/', '' | replace: '.html', '.md' %} + {% if filename == '' %}{% assign filename = 'getting-started.md' %}{% endif %}