cvsuser 04/11/10 07:41:32
Modified: App-Context/lib/App/Conf File.pm
Log:
change default order of searching for a config file
Revision Changes Path
1.8 +4 -4 p5ee/App-Context/lib/App/Conf/File.pm
Index: File.pm
===================================================================
RCS file: /cvs/public/p5ee/App-Context/lib/App/Conf/File.pm,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -r1.7 -r1.8
--- File.pm 27 Feb 2004 14:21:21 -0000 1.7
+++ File.pm 10 Nov 2004 15:41:32 -0000 1.8
@@ -1,10 +1,10 @@
#############################################################################
-## $Id: File.pm,v 1.7 2004/02/27 14:21:21 spadkins Exp $
+## $Id: File.pm,v 1.8 2004/11/10 15:41:32 spadkins Exp $
#############################################################################
package App::Conf::File;
-$VERSION = do { my @r=(q$Revision: 1.7 $=~/\d+/g); sprintf
"%d."."%02d"x$#r,@r};
+$VERSION = do { my @r=(q$Revision: 1.8 $=~/\d+/g); sprintf
"%d."."%02d"x$#r,@r};
use App;
use App::Conf;
@@ -73,10 +73,10 @@
$app = $options->{app} || "app";
$conf_type = $options->{conf_type} || "pl";
push(@conf_file, "$ENV{HOME}/.app/$app.$conf_type") if ($ENV{HOME}
&& $app ne "app");
- push(@conf_file, "$ENV{HOME}/.app/app.$conf_type") if ($ENV{HOME});
push(@conf_file, "$prog_dir/$app.$conf_type") if ($app ne "app");
- push(@conf_file, "$prog_dir/app.$conf_type");
push(@conf_file, "$prefix/etc/app/$app.$conf_type") if ($app ne
"app");
+ push(@conf_file, "$ENV{HOME}/.app/app.$conf_type") if ($ENV{HOME});
+ push(@conf_file, "$prog_dir/app.$conf_type");
push(@conf_file, "$prefix/etc/app/app.$conf_type");
}