-
Notifications
You must be signed in to change notification settings - Fork 38
/
Copy path_redirects
22 lines (20 loc) · 1.29 KB
/
_redirects
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
---
# will generate redirects from redirect_from in page frontmatter
---
https://www.mattgreydesign.com/* {{ site.url }}/:splat 301!
https://mattgreydesign.com/* {{ site.url }}/:splat 301!
http://www.mattgreydesign.com/* {{ site.url }}/:splat 301!
http://mattgreydesign.com/* {{ site.url }}/:splat 301!
/blog/* {{ site.url }}/:splat 301
/portfolio / 301
/projects / 301
/projects/social-networking-icons /fonts/ 301
/fonts/social-networking-icons /fonts/ 301
/projects/all-things-iced / 301
/projects/saving-lives-sea / 301
/projects/usa-just-brand / 301
{% for page in site.posts %}{% if page.redirect_from %}{{ page.redirect_from }} {{ page.url }} 301
{% endif %}{% endfor %}{% for page in site.html_pages %}{% if page.redirect_from %}{{ page.redirect_from }} {{ page.url }} 301
{% endif %}{% endfor %}{% for collection in site.collections %}{% unless collection.last.output == false or collection.output == false or collection.label == 'posts' %}{% for doc in collection.last.docs %}{% if doc.redirect_from %}{{ doc.redirect_from }} {{ doc.url | replace:'/index.html','/' | normalize_url }} 301
{% endif %}{% endfor %}{% for doc in collection.docs %}{% if doc.redirect_from %}
{{ doc.redirect_from }} {{ doc.url | replace:'/index.html','/' | normalize_url }} 301{% endif %}{% endfor %}{% endunless %}{% endfor %}