my $authorname = "Steve McIntyre";
my $authormail = '93sam@debian.org';
+sub set_default_config () {
+ $conf{'dbdir'} = "/home/steve/debian/debian-cd/search/search-db";
+ $conf{'htmldir'} = "/home/steve/debian/debian-cd/html";
+}
+
+# If we can find an appropriately-name config file, read it and
+# over-write the default config for $conf{'dbdir'} and $conf{'htmldir'}
+sub read_config () {
+ my $config_file;
+
+ $config_file = $0;
+ $config_file =~ s/find_file.cgi/find_file.cfg/;
+ if (-r $config_file) {
+ my $config = ConfigReader::Simple->new($config_file);
+ foreach my $key (keys %conf) {
+ if ($config->exists($key)) {
+ $conf{$key} = $config->get($key);
+ }
+ }
+ }
+}
+
sub read_files ($) {
my $lang = shift;
return $name;
}
-sub set_default_config () {
- $conf{'dbdir'} = "/home/steve/debian/debian-cd/search/search-db";
- $conf{'htmldir'} = "/home/steve/debian/debian-cd/html";
-}
-
-# If we can find an appropriately-name config file, read it and
-# over-write the default config for $conf{'dbdir'} and $conf{'htmldir'}
-sub read_config () {
- my $config_file;
-
- $config_file = $0;
- $config_file =~ s/find_file.cgi/find_file.cfg/;
- if (-r $config_file) {
- my $config = ConfigReader::Simple->new($config_file);
- foreach my $key (keys %conf) {
- if ($config->exists($key)) {
- $conf{$key} = $config->get($key);
- }
- }
- }
-}
-
set_default_config();
read_config();
read_files("en");