]> ruin.nu Git - ndwebbie.git/blobdiff - scripts/fetchdumps.pl
New structure for planet, surface and tech scans
[ndwebbie.git] / scripts / fetchdumps.pl
index 44a8d411eb7f00270ccb5c86545a78e70b61a67e..2579f38532688463e9b3a7a4ad07f0c6da32f7eb 100755 (executable)
@@ -27,7 +27,7 @@ use DBD::Pg qw(:pg_types);
 
 use LWP::Simple;
 
-use lib qw{/var/www/ndawn/};
+use lib qw{/var/www/ndawn/lib/};
 use ND::DB;
 
 our $dbh = ND::DB::DB();
@@ -50,12 +50,13 @@ for my $type ("planet","alliance","galaxy"){
        $select->finish;
 }
 
-if ($updated > 36){
+if ($updated){
        `/var/www/ndawn/scripts/parsealliances.pl $updated`;
        `/var/www/ndawn/scripts/parseplanets.pl $updated`;
        `/var/www/ndawn/scripts/parsegalaxies.pl $updated`;
        `/var/www/ndawn/scripts/ndrank.pl`;
        $dbh->do(q{UPDATE misc SET value = ? WHERE id = 'TICK'}, undef, $updated);
+       local $dbh->{Warn} = 0;
        $dbh->do(q{VACUUM ANALYZE});
 }