From eaab347e8949207f1d2bfae4ba1bb0826268e2b9 Mon Sep 17 00:00:00 2001 From: Marcelo Canina Date: Wed, 24 May 2017 19:42:13 -0300 Subject: [PATCH] redirects from default language subfolder to homepage --- Gemfile | 1 + Gemfile.lock | 5 ++++- README.md | 4 ++++ _config.yml | 1 + index.html | 2 ++ 5 files changed, 12 insertions(+), 1 deletion(-) diff --git a/Gemfile b/Gemfile index 6af252f..8236db2 100644 --- a/Gemfile +++ b/Gemfile @@ -10,4 +10,5 @@ group :jekyll_plugins do gem 'jekyll-sitemap' gem 'jekyll-toc' gem 'html-proofer' + gem 'jekyll-redirect-from' end diff --git a/Gemfile.lock b/Gemfile.lock index d660142..45f3b3c 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -38,6 +38,8 @@ GEM safe_yaml (~> 1.0) jekyll-feed (0.9.2) jekyll (~> 3.3) + jekyll-redirect-from (0.12.1) + jekyll (~> 3.3) jekyll-sass-converter (1.5.0) sass (~> 3.4) jekyll-seo-tag (2.2.3) @@ -82,9 +84,10 @@ DEPENDENCIES html-proofer jekyll jekyll-feed + jekyll-redirect-from jekyll-seo-tag jekyll-sitemap jekyll-toc BUNDLED WITH - 1.14.6 + 1.15.0 diff --git a/README.md b/README.md index adc7148..6d5b08e 100644 --- a/README.md +++ b/README.md @@ -114,6 +114,8 @@ Just clone this repo and start building yours. +- Redirects from default language subfolder to site homepage (`/en` -> `/`) + # Design Philosophy **jekyll-skeleton** has been built with the following principles in @@ -200,6 +202,8 @@ The following properties in posts front-matter are used: files to make sure they're accurate. - A Jekyll plugin to generate an Atom (RSS-like) feed of your Jekyll posts +- Specify multiple + redirections URLs for pages and posts. If you want to host a site derived from this repo in Github, you can follow this guide: [Automated Deployment Of Jekyll Websites To Github Pages With A Git Push To Github ](https://simpleit.rocks/automated-deployment-of-jekyll-websites-to-github-pages-with-a-git-push-to-github/). diff --git a/_config.yml b/_config.yml index 3df2bb8..7987f94 100644 --- a/_config.yml +++ b/_config.yml @@ -53,6 +53,7 @@ gems: - jekyll-sitemap - jekyll-feed - jekyll-seo-tag + - jekyll-redirect-from defaults: #languages diff --git a/index.html b/index.html index 7191026..bda67e2 100644 --- a/index.html +++ b/index.html @@ -1,6 +1,8 @@ --- title: Homepage example layout: home +redirect_from: + - /en/ # the default language subfolder redirects here --- Example home page, Hello World!