Changeset 69 in ProjectBuilder for devel/pb/lib/ProjectBuilder/pb.pm


Ignore:
Timestamp:
Aug 31, 2007, 3:20:15 PM (17 years ago)
Author:
Bruno Cornec
Message:

Rework interfaces of pb_init, conf files content and management to ease usage

File:
1 edited

Legend:

Unmodified
Added
Removed
  • devel/pb/lib/ProjectBuilder/pb.pm

    r50 r69  
    99use AppConfig qw(ARGCOUNT_HASH ARGCOUNT_ONE);
    1010use Data::Dumper;
    11 use vars qw (%pbroot);
    1211
    1312sub pb_init {
    1413
    1514my $conffile = shift;
     15my $param = shift;
    1616my $trace;
    1717
     
    3333                        });
    3434$config->file($conffile);
    35 my $ptr = $config->get("pbroot") || die "Unable to find pbroot in $conffile";
     35my $ptr = $config->get($param) || die "Unable to find $param in $conffile";
    3636print "DEBUG: pbroot: ".Dumper($ptr)."\n" if ($debug >= 1);
    37 %pbroot = %$ptr;
     37return($ptr);
    3838}
    3939
Note: See TracChangeset for help on using the changeset viewer.