Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
5 changed files
with
18 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
#!/bin/bash | ||
psql -c "update users set blocked='t' where id in (select id from users where score<-50 and nick!='anonymous' and max_score<150 and not blocked)" linux > /dev/null | ||
psql -c "update users set blocked='t' where id in (select id from users where score<-50 and nick!='anonymous' and max_score<150 and blocked is null)" linux > /dev/null | ||
psql -c "delete from users where not activated and regdate<CURRENT_TIMESTAMP-'1 week'::interval" linux > /dev/null |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
#!/bin/bash | ||
|
||
/usr/bin/psql -c "select stat_update()" linux >/dev/null | ||
sleep 3 | ||
/usr/bin/psql -c "set sort_mem=10240; select stat_update2()" linux >/dev/null | ||
sleep 3 | ||
/usr/bin/psql -c "select update_monthly_stats()" linux > /dev/null | ||
/usr/bin/psql -c "select set_role_map()" linux > /dev/null |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
#!/bin/bash | ||
|
||
/usr/bin/lynx -source http://www.linux.org.ru/_topstat.jsp > /dev/null |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
psql -c "update users set score=score+1 where id in (select distinct comments.userid from comments, topics where comments.postdate>'yesterday' and topics.id=comments.topic and groupid!=8404 and groupid!=4068 and groupid!=19390 and not comments.deleted and not topics.deleted)" linux > /dev/null | ||
psql -c "update users set max_score=score where score>max_score" linux > /dev/null |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters