[Catalyst-commits] r6391 - trunk/Catalyst-Plugin-Static-Simple

andyg at dev.catalyst.perl.org andyg at dev.catalyst.perl.org
Fri May 11 16:27:05 GMT 2007


Author: andyg
Date: 2007-05-11 16:27:01 +0100 (Fri, 11 May 2007)
New Revision: 6391

Modified:
   trunk/Catalyst-Plugin-Static-Simple/Changes
   trunk/Catalyst-Plugin-Static-Simple/README
Log:
Static::Simple 0.17

Modified: trunk/Catalyst-Plugin-Static-Simple/Changes
===================================================================
--- trunk/Catalyst-Plugin-Static-Simple/Changes	2007-05-11 15:18:49 UTC (rev 6390)
+++ trunk/Catalyst-Plugin-Static-Simple/Changes	2007-05-11 15:27:01 UTC (rev 6391)
@@ -1,5 +1,5 @@
 Revision history for Perl extension Catalyst::Plugin::Static::Simple
-0.17    
+0.17    2007-05-11 11:00:00
         - Added serve_static_file, to serve a given file as static. (groditi)
 
 0.16    2007-04-30 15:00:00

Modified: trunk/Catalyst-Plugin-Static-Simple/README
===================================================================
--- trunk/Catalyst-Plugin-Static-Simple/README	2007-05-11 15:18:49 UTC (rev 6390)
+++ trunk/Catalyst-Plugin-Static-Simple/README	2007-05-11 15:27:01 UTC (rev 6391)
@@ -172,6 +172,20 @@
     application, and it will continue to function on a development server,
     or using Catalyst's built-in server.
 
+PUBLIC METHODS
+  serve_static_file $file_path
+    Will serve the file located in $file_path statically. This is useful
+    when you need to autogenerate them if they don't exist, or they are
+    stored in a model.
+
+        package MyApp::Controller::User;
+
+        sub curr_user_thumb : PathPart("my_thumbnail.png") {
+            my ( $self, $c ) = @_;
+            my $file_path = $c->user->picture_thumbnail_path;
+            $c->serve_static_file($file_path);
+        }
+
 INTERNAL EXTENDED METHODS
     Static::Simple extends the following steps in the Catalyst process.
 
@@ -199,8 +213,12 @@
     Andy Grundman, <andy at hybridized.org>
 
 CONTRIBUTORS
-    Marcus Ramberg, <mramberg at cpan.org> Jesse Sheidlower, <jester at panix.com>
+    Marcus Ramberg, <mramberg at cpan.org>
 
+    Jesse Sheidlower, <jester at panix.com>
+
+    Guillermo Roditi, <groditi at cpan.org>
+
 THANKS
     The authors of Catalyst::Plugin::Static:
 




More information about the Catalyst-commits mailing list