blob: 3d6b33f66b3efa0c4cae4e738a114f0f3cee13a8 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
|
#!/bin/sh
cd /var/www/bugs.gentoo.org/htdocs
custom_buglist="https://bugs.gentoo.org/custom_buglist.cgi"
[ ! -d "data/cached/" ] && mkdir -p data/cached/
outpath="/var/www/bugs.gentoo.org/htdocs/data/cached"
./collectstats.pl
dofile() {
url="$1"
outfile="$2"
tmp="${outfile}.$$"
#echo $url
# wget -q "$url" -O "${tmp}" --header 'Host: bugs.gentoo.org'
curl -sS --resolve bugs.gentoo.org:443:127.0.0.1 "${url}" -o "${tmp}"
if [ $? -eq 0 ]; then
gzip -9 <"${tmp}" >"${tmp}.gz"
mv -f "${tmp}" "${outfile}"
mv -f "${tmp}.gz" "${outfile}gz"
else
rm -f "${tmp}" "${tmp}.gz" "${outfile}" "${outfile}gz"
fi
}
for status in RESOLVED VERIFIED ; do
for reso in FIXED INVALID WONTFIX LATER REMIND WORKSFORME CANTFIX NEEDINFO TEST-REQUEST UPSTREAM OBSOLETE; do
dofile "$custom_buglist?reso=${reso}&status=${status}" ${outpath}/buglist-${status}-${reso}.html
done
done
for status in UNCONFIRMED CONFIRMED IN_PROGRESS ; do
dofile "$custom_buglist?status=${status}" ${outpath}/buglist-${status}.html
done
|