<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array">
    <added>
      <filename>CHANGELOG</filename>
    </added>
    <added>
      <filename>test/test_helper.rb</filename>
    </added>
  </added>
  <modified type="array">
    <modified>
      <diff>@@ -1,50 +1,60 @@
-Railspdf
-========
+railspdf
 
+Adds pdf-writer support to Rails
 
-To begin rendering PDF's, simply create a view with a .rpdf extension and paste in the code:
 
-[code]
+Usage
+-----
 
-pdf.select_font &quot;Times-Roman&quot;
+To begin rendering PDFs, simply create a view with a .rpdf extension and paste in the code:
 
-pdf.text &quot;Hello, World&quot;, :font_size =&gt; 72, :justification =&gt; :center
+  pdf.select_font &quot;Times-Roman&quot;
+  pdf.text &quot;Hello, World&quot;, :font_size =&gt; 72, :justification =&gt; :center
 
-[/code]
+If you want the text to be dynamic, simply replace &quot;Hello World&quot; with an instance variable. It works like a charm, although I had to rearrange the code a bit to make it work. (See the sample controller code at the bottom.)
 
-If you want the text to be dynamic, simply replace &quot;Hello World&quot; with an instance variable. It works like a charm, although I had to rearrange the code a bit to make it work. (Sample Code at the bottom)
+I've not yet tested any of this; I was just too excited once it started working. Note: to get plugins to work properly, you MUST restart the server after installing it.
 
-I've not yet tested any of this; I was just too excited once it started working. Note: to get plugins to work properly, you _must_ restart the server after installing it.
-
-          o Important** If you are using a layout, you must disable it for the view!!! 
+  **Important** If you are using a layout, you must disable it for the view!!! 
 
 The default filename for the pdf is &quot;Default.pdf&quot; I'll probably change that later to reflect the view name, but for now it works pretty good. To override it, set an instance variable in your controller named &quot;@rails_pdf_name&quot; The rendered pdf will take this filename.
 
-Ok, I think that is all for now. Please let me know if you have any questions.
-
-Contoller Code &gt;
+Please let me know if you have any questions.
 
-class PagesController? &lt; ApplicationController?
 
-  def index
+Sample Controller
+-----------------
 
+  class PagesController &lt; ApplicationController
+    def getpdf
+    	@rails_pdf_name = &quot;Hello.pdf&quot;
+    	@content = &quot;This is dynamic content!!!&quot;
+    end
   end
 
-  def getpdf
-  	@rails_pdf_name = &quot;Hello.pdf&quot;
-  	@content = &quot;This is dynamic content!!!&quot;
-  end
 
-end
+Sample View
+-----------
+
+  pdf.select_font &quot;Times-Roman&quot;
+  pdf.text @content, :font_size =&gt; 72, :justification =&gt; :center
+
+
+Misc
+----
 
-File: &quot;getpdf.rpdf&quot;
+Original RubyForge project (outdated):
+  http://rubyforge.org/projects/railspdfplugin/
 
-pdf.select_font &quot;Times-Roman&quot;
+GitHub fork:
+  http://github.com/pelargir/railspdf/
 
-pdf.text @content, :font_size =&gt; 72, :justification =&gt; :center
+Clone URL:
+  git://github.com/pelargir/railspdf.git
 
-File: &quot;index.rhtml&quot;
 
-Get yo fish and dynamic pdf's!&lt;br /&gt;&lt;br /&gt;
+Credit
+------
 
-&lt;%= link_to( &quot;Get PDF&quot;, :controller =&gt; &quot;pages&quot;, :action =&gt; &quot;getpdf&quot; )%&gt; 
\ No newline at end of file
+  * Created by Tom Willett
+  * Forked and updated by Matthew Bass &lt;pelargir@gmail.com&gt;</diff>
      <filename>README</filename>
    </modified>
    <modified>
      <diff>@@ -1,3 +1,3 @@
-require &quot;railspdf&quot;
+require 'railspdf'
 
 ActionView::Template.register_template_handler 'rpdf', RailsPDF::PDFRender
\ No newline at end of file</diff>
      <filename>init.rb</filename>
    </modified>
    <modified>
      <diff>@@ -1,4 +1,3 @@
-# Railspdf
 require 'pdf/writer'
 require 'pdf/simpletable'
 
@@ -6,57 +5,57 @@ module RailsPDF
   
  	#this code comes from http://wiki.rubyonrails.com/rails/pages/HowtoGeneratePDFs 	
 	class PDFRender &lt; ActionView::Base
-    	include ApplicationHelper
+  	include ApplicationHelper
 
-    	def initialize(action_view)
-      		@action_view = action_view
-    			prefix = action_view.controller.class.to_s.gsub(/Controller/, '')
-          self.class.send(:include, &quot;#{prefix}Helper&quot;.constantize)
-    	end
+  	def initialize(action_view)
+    		@action_view = action_view
+  			prefix = action_view.controller.class.to_s.gsub(/Controller/, '')
+        self.class.send(:include, &quot;#{prefix}Helper&quot;.constantize)
+  	end
 
-    
-	    def render(template, local_assigns = {})
-	    	
-      	#get the instance variables setup	    	
-     		@action_view.controller.instance_variables.each do |v|
-         		instance_variable_set(v, @action_view.controller.instance_variable_get(v))
-        end
-			
-  			#keep ie happy
-  			if @action_view.controller.request.env['HTTP_USER_AGENT'] =~ /msie/i
-          		@action_view.controller.headers['Pragma'] ||= ''
-          		@action_view.controller.headers['Cache-Control'] ||= ''
-     		else
-          		@action_view.controller.headers['Pragma'] ||= 'no-cache'
-          		@action_view.controller.headers['Cache-Control'] ||= 'no-cache, must-revalidate'
-     		end
-     		
-     		
-     		@action_view.controller.headers[&quot;Content-Type&quot;] ||= 'application/pdf'
-  			if @rails_pdf_name
-  				@action_view.controller.headers[&quot;Content-Disposition&quot;] ||= 'attachment; filename=&quot;' + @rails_pdf_name + '&quot;'
-  			elsif @rails_pdf_inline
-  				#set no headers
-  			else #rails_pdf_inline was set to false.  set filename = controller name
-  				 #since we weren't provided a custom name
-  				@action_view.controller.headers[&quot;Content-Disposition&quot;] ||= 'attachment; filename=&quot;' + @action_view.controller.controller_name + '.pdf' + '&quot;'
-  			end
-        
-        if @landscape
-       		pdf = PDF::Writer.new( :paper =&gt; (@paper || 'A4'), :orientation =&gt; :landscape )
-        else
-       		pdf = PDF::Writer.new( :paper =&gt; (@paper || 'A4') )
-        end
-   	  	pdf.compressed = true if RAILS_ENV != 'development'
-   	  	
-   	  	File.open(&quot;foo.txt&quot;,File::CREAT|File::TRUNC|File::RDWR).write(template.source)
-   	  	
-  	    eval template.source, nil, &quot;#{@action_view.base_path}/#{@action_view.first_render}.#{@action_view.finder.pick_template_extension(@action_view.first_render)}&quot; 
-     		pdf.render
-    	end
+  
+    def render(template, local_assigns = {})
     	
-    	def compilable?
-        false
+    	#get the instance variables setup	    	
+   		@action_view.controller.instance_variables.each do |v|
+       		instance_variable_set(v, @action_view.controller.instance_variable_get(v))
+      end
+		
+			#keep ie happy
+			if @action_view.controller.request.env['HTTP_USER_AGENT'] =~ /msie/i
+        		@action_view.controller.headers['Pragma'] ||= ''
+        		@action_view.controller.headers['Cache-Control'] ||= ''
+   		else
+        		@action_view.controller.headers['Pragma'] ||= 'no-cache'
+        		@action_view.controller.headers['Cache-Control'] ||= 'no-cache, must-revalidate'
+   		end
+   		
+   		
+   		@action_view.controller.headers[&quot;Content-Type&quot;] ||= 'application/pdf'
+			if @rails_pdf_name
+				@action_view.controller.headers[&quot;Content-Disposition&quot;] ||= 'attachment; filename=&quot;' + @rails_pdf_name + '&quot;'
+			elsif @rails_pdf_inline
+				#set no headers
+			else #rails_pdf_inline was set to false.  set filename = controller name
+				 #since we weren't provided a custom name
+				@action_view.controller.headers[&quot;Content-Disposition&quot;] ||= 'attachment; filename=&quot;' + @action_view.controller.controller_name + '.pdf' + '&quot;'
+			end
+      
+      if @landscape
+     		pdf = PDF::Writer.new( :paper =&gt; (@paper || 'A4'), :orientation =&gt; :landscape )
+      else
+     		pdf = PDF::Writer.new( :paper =&gt; (@paper || 'A4') )
       end
+ 	  	pdf.compressed = true if RAILS_ENV != 'development'
+ 	  	
+ 	  	File.open(&quot;foo.txt&quot;,File::CREAT|File::TRUNC|File::RDWR).write(template.source)
+ 	  	
+	    eval template.source, nil, &quot;#{@action_view.base_path}/#{@action_view.first_render}.#{@action_view.finder.pick_template_extension(@action_view.first_render)}&quot; 
+   		pdf.render
+  	end
+  	
+  	def compilable?
+      false
+    end
   end
 end</diff>
      <filename>lib/railspdf.rb</filename>
    </modified>
    <modified>
      <diff>@@ -1,8 +1,12 @@
-require 'test/unit'
+require File.dirname(__FILE__) + '/test_helper'
 
-class RailspdfTest &lt; Test::Unit::TestCase
-  # Replace this with your real tests.
-  def test_this_plugin
-    flunk
+class SomeController; end
+module SomeHelper; end
+
+class RailsPDF::PDFRenderTest &lt; Test::Unit::TestCase
+  def test_should_not_be_compilable
+    view = stub(:controller =&gt; SomeController.new)
+    pdf = RailsPDF::PDFRender.new(view)
+    assert !pdf.compilable?
   end
 end</diff>
      <filename>test/railspdf_test.rb</filename>
    </modified>
  </modified>
  <removed type="array">
    <removed>
      <filename>tasks/railspdf_tasks.rake</filename>
    </removed>
  </removed>
  <parents type="array">
    <parent>
      <id>a63d21457f678cd5c6031a15fe4babc5f6f166a2</id>
    </parent>
  </parents>
  <author>
    <name>Matthew Bass</name>
    <email>matt@anacreon.local</email>
  </author>
  <url>http://github.com/pelargir/railspdf/commit/95794bfb0b4b88725e51e0e4a339557bd41d71ff</url>
  <id>95794bfb0b4b88725e51e0e4a339557bd41d71ff</id>
  <committed-date>2008-06-09T15:28:26-07:00</committed-date>
  <authored-date>2008-06-09T15:28:26-07:00</authored-date>
  <message>added CHANGELOG and tests</message>
  <tree>fac3f63e2e27ae79f04e57f7b7acc135cbebcb65</tree>
  <committer>
    <name>Matthew Bass</name>
    <email>matt@anacreon.local</email>
  </committer>
</commit>
