<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array">
    <added>
      <filename>views/posts/tags.haml</filename>
    </added>
  </added>
  <modified type="array">
    <modified>
      <diff>@@ -63,6 +63,13 @@ put '/posts/:id' do
   redirect &quot;/posts/#{@post.id}&quot;
 end
 
+get '/posts/tags/:tags' do
+  @tags = params[:tags]
+  @tags = @tags.split(',') if @tags =~ /,/
+  @posts = Post.all( :conditions =&gt; { :tags =&gt; @tags }, :order =&gt; 'created_at desc' )
+  haml :&quot;posts/tags&quot;
+end
+
 post '/posts/:post_id/comments' do
   @comment = Comment.create(params)
   cleanup @comment</diff>
      <filename>app.rb</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>0c496e462d50664bde1f9b853b56abd701565f17</id>
    </parent>
  </parents>
  <author>
    <name>Will Farrington</name>
    <email>will@railsmachine.com</email>
  </author>
  <url>http://github.com/skalnik/mango/commit/7ee95377fc1adbb8625e2b0c483faf01a496f7ea</url>
  <id>7ee95377fc1adbb8625e2b0c483faf01a496f7ea</id>
  <committed-date>2009-10-25T19:03:57-07:00</committed-date>
  <authored-date>2009-10-25T19:03:57-07:00</authored-date>
  <message>Add a view and routing for viewing posts by tag(s).</message>
  <tree>61217e495e9dbcdfd3f7128196ae55b39db09096</tree>
  <committer>
    <name>Will Farrington</name>
    <email>will@railsmachine.com</email>
  </committer>
</commit>
