[Jifty-commit] r872 - in jifty/trunk: lib/Jifty

jifty-commit at lists.jifty.org jifty-commit at lists.jifty.org
Wed Apr 19 22:03:27 EDT 2006


Author: alexmv
Date: Wed Apr 19 22:03:26 2006
New Revision: 872

Modified:
   jifty/trunk/   (props changed)
   jifty/trunk/lib/Jifty/Config.pm
   jifty/trunk/lib/Jifty/Util.pm

Log:
 r12440 at zoq-fot-pik:  chmrr | 2006-04-19 22:01:56 -0400
  * Don't use absolute paths in the config file; use %percents% to mark
 them as to be made absolute when read
  * Return undef if we can't guess the app path


Modified: jifty/trunk/lib/Jifty/Config.pm
==============================================================================
--- jifty/trunk/lib/Jifty/Config.pm	(original)
+++ jifty/trunk/lib/Jifty/Config.pm	Wed Apr 19 22:03:26 2006
@@ -209,8 +209,6 @@
     my $db_name = lc $app_name;
     $db_name =~ s/-/_/g;
 
-    my $app_root = Jifty::Util->app_root;
-
     return {
         framework => {
             AdminMode        => 1,
@@ -232,15 +230,15 @@
             Mailer     => 'Sendmail',
             MailerArgs => [],
             L10N       => {
-                PoDir => "$app_root/share/po",
+                PoDir => "%share/po%",
             },
             Web        => {
                 Port => '8888',
                 BaseURL => 'http://localhost',
-                SessionDir  => "$app_root/var/session",
-                DataDir     => "$app_root/var/mason",
-                StaticRoot   => "$app_root/share/web/static",
-                TemplateRoot => "$app_root/share/web/templates",
+                SessionDir  => "%var/session%",
+                DataDir     => "%var/mason%",
+                StaticRoot   => "%share/web/static%",
+                TemplateRoot => "%share/web/templates%",
                 ServeStaticFiles => 1,
                 MasonConfig => {
                     autoflush    => 0,

Modified: jifty/trunk/lib/Jifty/Util.pm
==============================================================================
--- jifty/trunk/lib/Jifty/Util.pm	(original)
+++ jifty/trunk/lib/Jifty/Util.pm	Wed Apr 19 22:03:26 2006
@@ -124,6 +124,7 @@
     warn "Can't guess application root from current path ("
         . Cwd::cwd()
         . ") or bin path ($FindBin::Bin)\n";
+    return undef;
 }
 
 =head2 default_app_name


More information about the Jifty-commit mailing list