-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add script for downloading scummvm logs
- Loading branch information
1 parent
711aa54
commit 9f4d1e7
Showing
5 changed files
with
199 additions
and
0 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,49 @@ | ||
#!/bin/bash | ||
|
||
days=$(seq 1 31) | ||
months="Jan Feb Mar Apr May Jun Jul Aug Sep Oct Nov Dec" | ||
years=$(seq 2003 2017) | ||
|
||
isleap() { | ||
year=$1 | ||
if [ $((year % 4)) -eq 0 ]; then | ||
if [ $((year % 100)) -eq 0 ]; then | ||
if [ $((year % 400)) -eq 0 ]; then | ||
return 0 | ||
else | ||
return 1 | ||
fi | ||
else | ||
return 1 | ||
fi | ||
else | ||
return 1 | ||
fi | ||
} | ||
|
||
for year in $years | ||
do | ||
for month in $months | ||
do | ||
# set days correctly according to month and leap/nonleap year | ||
if [ $month = "Jan" ] || [ $month = "Mar" ] || [ $month = "May" ] || [ $month = "Jul" ] || [ $month = "Aug" ] || [ $month = "Oct" ] || [ $month = "Dec" ]; then | ||
days=$(seq 1 31) | ||
elif [ $month = "Apr" ] || [ $month = "Jun" ] || [ $month = "Sep" ] || [ $month = "Nov" ] ; then | ||
days=$(seq 1 30) | ||
elif [ $month = "Feb" ] && isleap $year; then | ||
days=$(seq 1 29) | ||
elif [ $month = "Feb" ] && ! isleap $year; then | ||
days=$(seq 1 28) | ||
fi; | ||
for day in $days | ||
do | ||
path=logs/${year}/${month}/${day} | ||
echo "Downloading logs to $path" | ||
mkdir -p ${path} | ||
touch "${path}/#scummvm.txt" | ||
wget -o log -O "${path}/#scummvm.txt" http://www.enderboi.com/log.php?log=scummvm.log.${day}${month}${year}&format=text | ||
# sleep for random time between 1 and 20 seconds | ||
sleep `shuf -i 1-20 -n 1` | ||
done | ||
done | ||
done |
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,6 @@ | ||
#!/bin/bash | ||
for i in `cat slackware_source.txt` | ||
do | ||
wget -A log -r -l 3 $i | ||
sleep `shuf -i 1-5 -n 1` | ||
done |
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 @@ | ||
https://phra.gs/logs/2014/ | ||
https://phra.gs/logs/2015/ |
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,6 @@ | ||
#!/bin/zsh | ||
for i in `cat pending.txt` | ||
do | ||
wget -A txt -r -l 3 $i | ||
sleep 5 | ||
done |
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,136 @@ | ||
http://irclogs.ubuntu.com/2004/09 | ||
http://irclogs.ubuntu.com/2004/10 | ||
http://irclogs.ubuntu.com/2004/11 | ||
http://irclogs.ubuntu.com/2004/12 | ||
http://irclogs.ubuntu.com/2005/01 | ||
http://irclogs.ubuntu.com/2005/02 | ||
http://irclogs.ubuntu.com/2005/03 | ||
http://irclogs.ubuntu.com/2005/04 | ||
http://irclogs.ubuntu.com/2005/05 | ||
http://irclogs.ubuntu.com/2005/06 | ||
http://irclogs.ubuntu.com/2005/07 | ||
http://irclogs.ubuntu.com/2005/08 | ||
http://irclogs.ubuntu.com/2005/09 | ||
http://irclogs.ubuntu.com/2005/10 | ||
http://irclogs.ubuntu.com/2005/11 | ||
http://irclogs.ubuntu.com/2005/12 | ||
http://irclogs.ubuntu.com/2006/01 | ||
http://irclogs.ubuntu.com/2006/02 | ||
http://irclogs.ubuntu.com/2006/03 | ||
http://irclogs.ubuntu.com/2006/04 | ||
http://irclogs.ubuntu.com/2006/05 | ||
http://irclogs.ubuntu.com/2006/06 | ||
http://irclogs.ubuntu.com/2006/07 | ||
http://irclogs.ubuntu.com/2006/08 | ||
http://irclogs.ubuntu.com/2006/09 | ||
http://irclogs.ubuntu.com/2006/10 | ||
http://irclogs.ubuntu.com/2006/11 | ||
http://irclogs.ubuntu.com/2006/12 | ||
http://irclogs.ubuntu.com/2007/01 | ||
http://irclogs.ubuntu.com/2007/02 | ||
http://irclogs.ubuntu.com/2007/03 | ||
http://irclogs.ubuntu.com/2007/04 | ||
http://irclogs.ubuntu.com/2007/05 | ||
http://irclogs.ubuntu.com/2007/06 | ||
http://irclogs.ubuntu.com/2007/07 | ||
http://irclogs.ubuntu.com/2007/08 | ||
http://irclogs.ubuntu.com/2007/09 | ||
http://irclogs.ubuntu.com/2007/10 | ||
http://irclogs.ubuntu.com/2007/11 | ||
http://irclogs.ubuntu.com/2007/12 | ||
http://irclogs.ubuntu.com/2008/01 | ||
http://irclogs.ubuntu.com/2008/02 | ||
http://irclogs.ubuntu.com/2008/03 | ||
http://irclogs.ubuntu.com/2008/04 | ||
http://irclogs.ubuntu.com/2008/05 | ||
http://irclogs.ubuntu.com/2008/06 | ||
http://irclogs.ubuntu.com/2008/07 | ||
http://irclogs.ubuntu.com/2008/08 | ||
http://irclogs.ubuntu.com/2008/09 | ||
http://irclogs.ubuntu.com/2008/10 | ||
http://irclogs.ubuntu.com/2008/11 | ||
http://irclogs.ubuntu.com/2008/12 | ||
http://irclogs.ubuntu.com/2009/01 | ||
http://irclogs.ubuntu.com/2009/02 | ||
http://irclogs.ubuntu.com/2009/03 | ||
http://irclogs.ubuntu.com/2009/04 | ||
http://irclogs.ubuntu.com/2009/05 | ||
http://irclogs.ubuntu.com/2009/06 | ||
http://irclogs.ubuntu.com/2009/07 | ||
http://irclogs.ubuntu.com/2009/08 | ||
http://irclogs.ubuntu.com/2009/09 | ||
http://irclogs.ubuntu.com/2009/10 | ||
http://irclogs.ubuntu.com/2009/11 | ||
http://irclogs.ubuntu.com/2009/12 | ||
http://irclogs.ubuntu.com/2010/01 | ||
http://irclogs.ubuntu.com/2010/02 | ||
http://irclogs.ubuntu.com/2010/03 | ||
http://irclogs.ubuntu.com/2010/04 | ||
http://irclogs.ubuntu.com/2010/05 | ||
http://irclogs.ubuntu.com/2010/06 | ||
http://irclogs.ubuntu.com/2010/07 | ||
http://irclogs.ubuntu.com/2010/08 | ||
http://irclogs.ubuntu.com/2010/09 | ||
http://irclogs.ubuntu.com/2010/10 | ||
http://irclogs.ubuntu.com/2010/11 | ||
http://irclogs.ubuntu.com/2010/12 | ||
http://irclogs.ubuntu.com/2011/01 | ||
http://irclogs.ubuntu.com/2011/02 | ||
http://irclogs.ubuntu.com/2011/03 | ||
http://irclogs.ubuntu.com/2011/04 | ||
http://irclogs.ubuntu.com/2011/05 | ||
http://irclogs.ubuntu.com/2011/06 | ||
http://irclogs.ubuntu.com/2011/07 | ||
http://irclogs.ubuntu.com/2011/08 | ||
http://irclogs.ubuntu.com/2011/09 | ||
http://irclogs.ubuntu.com/2011/10 | ||
http://irclogs.ubuntu.com/2011/11 | ||
http://irclogs.ubuntu.com/2011/12 | ||
http://irclogs.ubuntu.com/2012/01 | ||
http://irclogs.ubuntu.com/2012/02 | ||
http://irclogs.ubuntu.com/2012/03 | ||
http://irclogs.ubuntu.com/2012/04 | ||
http://irclogs.ubuntu.com/2012/05 | ||
http://irclogs.ubuntu.com/2012/06 | ||
http://irclogs.ubuntu.com/2012/07 | ||
http://irclogs.ubuntu.com/2012/08 | ||
http://irclogs.ubuntu.com/2012/09 | ||
http://irclogs.ubuntu.com/2012/10 | ||
http://irclogs.ubuntu.com/2012/11 | ||
http://irclogs.ubuntu.com/2012/12 | ||
http://irclogs.ubuntu.com/2013/01 | ||
http://irclogs.ubuntu.com/2013/02 | ||
http://irclogs.ubuntu.com/2013/03 | ||
http://irclogs.ubuntu.com/2013/04 | ||
http://irclogs.ubuntu.com/2013/05 | ||
http://irclogs.ubuntu.com/2013/06 | ||
http://irclogs.ubuntu.com/2013/07 | ||
http://irclogs.ubuntu.com/2013/08 | ||
http://irclogs.ubuntu.com/2013/09 | ||
http://irclogs.ubuntu.com/2013/10 | ||
http://irclogs.ubuntu.com/2013/11 | ||
http://irclogs.ubuntu.com/2013/12 | ||
http://irclogs.ubuntu.com/2014/01 | ||
http://irclogs.ubuntu.com/2014/02 | ||
http://irclogs.ubuntu.com/2014/03 | ||
http://irclogs.ubuntu.com/2014/04 | ||
http://irclogs.ubuntu.com/2014/05 | ||
http://irclogs.ubuntu.com/2014/06 | ||
http://irclogs.ubuntu.com/2014/07 | ||
http://irclogs.ubuntu.com/2014/08 | ||
http://irclogs.ubuntu.com/2014/09 | ||
http://irclogs.ubuntu.com/2014/10 | ||
http://irclogs.ubuntu.com/2014/11 | ||
http://irclogs.ubuntu.com/2014/12 | ||
http://irclogs.ubuntu.com/2015/01 | ||
http://irclogs.ubuntu.com/2015/02 | ||
http://irclogs.ubuntu.com/2015/03 | ||
http://irclogs.ubuntu.com/2015/04 | ||
http://irclogs.ubuntu.com/2015/05 | ||
http://irclogs.ubuntu.com/2015/06 | ||
http://irclogs.ubuntu.com/2015/07 | ||
http://irclogs.ubuntu.com/2015/08 | ||
http://irclogs.ubuntu.com/2015/09 | ||
http://irclogs.ubuntu.com/2015/10 | ||
http://irclogs.ubuntu.com/2015/11 | ||
http://irclogs.ubuntu.com/2015/12 |