Remove the old redirect system.

This commit is contained in:
Chris Eppstein 2010-12-18 14:29:12 -08:00
parent 7c323feb31
commit ff6c3a078a
4 changed files with 5 additions and 13 deletions

View File

@ -18,7 +18,7 @@ end
compile '/' do compile '/' do
filter :haml, :ugly => true filter :haml, :ugly => true
layout item[:redirect] ? "redirect" : (item[:layout] ? item[:layout] : "main") layout item[:layout] ? item[:layout] : "main"
end end
compile '/search-data/' do compile '/search-data/' do
@ -28,7 +28,7 @@ end
compile '/examples/*/' do compile '/examples/*/' do
filter :haml, :ugly => true filter :haml, :ugly => true
filter :highlight filter :highlight
layout item[:redirect] ? "redirect" : (item[:layout] ? item[:layout] : "example") layout item[:layout] ? item[:layout] : "example"
end end
sass_options = Compass.sass_engine_options sass_options = Compass.sass_engine_options
@ -44,7 +44,7 @@ end
compile '/reference/*/' do compile '/reference/*/' do
filter :haml, :ugly => true filter :haml, :ugly => true
filter :highlight filter :highlight
layout item[:redirect] ? "redirect" : (item[:layout] ? item[:layout] : "main") layout item[:layout] ? item[:layout] : "main"
end end
compile '*' do compile '*' do
@ -53,7 +53,7 @@ compile '*' do
elsif item[:extension] == "haml" elsif item[:extension] == "haml"
filter :haml, :ugly => true filter :haml, :ugly => true
end end
layout item[:redirect] ? "redirect" : (item[:layout] ? item[:layout] : "main") layout item[:layout] ? item[:layout] : "main"
end end
route '/search-data/' do route '/search-data/' do

View File

@ -1,4 +1,5 @@
RedirectMatch 301 /docs/ /reference/compass/ RedirectMatch 301 /docs/ /reference/compass/
RedirectMatch 301 /docs/tutorials/(.*) /help/tutorials/$1 RedirectMatch 301 /docs/tutorials/(.*) /help/tutorials/$1
RedirectMatch 301 /docs/(.*) /$1 RedirectMatch 301 /docs/(.*) /$1
RedirectMatch 301 /reference/ /reference/compass/

View File

@ -1,4 +0,0 @@
---
title: Compass Documentation
redirect: /reference/compass/
---

View File

@ -1,5 +0,0 @@
!!!5
- # This template redirects.
%html{:dir => "ltr", :lang => "en"}
%head
%meta{:"http-equiv" => "refresh", :content => "0;#{@item[:redirect]}"}/