# HG changeset patch # User "Rex Tsai " # Date 1223465274 -28800 # Node ID 552528bb491758209ac840902d8d0ff9a39a27f2 # Parent d5e02a25b0002b4793bddfd49b9ac24c2aace7f9 refined the cache timeout is 12 hours. diff -r d5e02a25b000 -r 552528bb4917 .hgignore --- a/.hgignore Wed Oct 08 19:25:31 2008 +0800 +++ b/.hgignore Wed Oct 08 19:27:54 2008 +0800 @@ -1,7 +1,8 @@ -syntax=regexp +syntax: glob cookies.txt ikariam.sqlite perl samples sheep.sh sheep.txt +*.html diff -r d5e02a25b000 -r 552528bb4917 scan.pl --- a/scan.pl Wed Oct 08 19:25:31 2008 +0800 +++ b/scan.pl Wed Oct 08 19:27:54 2008 +0800 @@ -29,7 +29,7 @@ printf("city %d %s saved\n", $city->{cityId}, $city->{cityname}); if(my $user = Ikariam::User->retrieve($city->{user})) { - if($user->time le (time - 60*60)) { + if($user->time le (time - 60*60*12)) { # Download user profile. foreach my $x (qw/score army_score_main trader_score_secondary/) { diff -r d5e02a25b000 -r 552528bb4917 sheep.pl --- a/sheep.pl Wed Oct 08 19:25:31 2008 +0800 +++ b/sheep.pl Wed Oct 08 19:27:54 2008 +0800 @@ -19,6 +19,7 @@ AND cities.status = 'i' } ); + Ikariam::User->set_sql(sheeps => qq { SELECT user.id FROM user, cities, island