Permalink
Browse files

Added redirects to new locations of posts at posterous

  • Loading branch information...
0 parents commit 8dfdc13cc67738eed7b66e45fbe1eb7f1c27a604 @opsb committed Jan 7, 2011
Showing with 44 additions and 0 deletions.
  1. +3 −0 Gemfile
  2. +14 −0 Gemfile.lock
  3. +27 −0 config.ru
@@ -0,0 +1,3 @@
+source :rubygems
+
+gem 'sinatra'
@@ -0,0 +1,14 @@
+GEM
+ remote: http://rubygems.org/
+ specs:
+ rack (1.2.1)
+ sinatra (1.1.0)
+ rack (~> 1.1)
+ tilt (~> 1.1)
+ tilt (1.1)
+
+PLATFORMS
+ ruby
+
+DEPENDENCIES
+ sinatra
@@ -0,0 +1,27 @@
+require 'rubygems'
+require 'bundler'
+Bundler.setup
+require 'sinatra'
+
+URL_MAPPINGS = {
+ '176' => 'introducing-butler-io',
+ '165' => 'follow-table-links-in-cucumber',
+ '163' => 'rcov-for-cucumber-and-shoulda',
+ '149' => 'validates-uniqueness-of-multiple-columns',
+ '122' => 'put-your-team-back-together-with-some-promisc',
+ '88' => 'getting-started-with-ruby-dbi-and-mysql',
+ '75' => 'useful-regular-expressions-with-egrep',
+ '56' => 'pimp-my-git',
+ '53' => 'git-rebase-from-another-repository',
+ '50' => 'native-ruby-gems-on-ubuntu',
+ '41' => 'instant-remote-git-repository-using-ssh',
+ '32' => 'getting-started-with-git-github-and-eclipse-o',
+ '3' => 'getting-started-with-git-github-and-eclipse-p'
+}
+
+get '/' do
+ redirect "http://blog.opsb.co.uk/" + URL_MAPPINGS[params['p']].to_s, 301
+end
+
+run Sinatra::Application
+

0 comments on commit 8dfdc13

Please sign in to comment.