-
Notifications
You must be signed in to change notification settings - Fork 20
/
get_stats.sh
executable file
·24 lines (22 loc) · 1.18 KB
/
get_stats.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
# This script is the same as https://github.com/IATI/IATI-Stats/blob/master/get_stats.sh
# but with only the dated historical aggregates.
mkdir stats-calculated
for f in ckan gitdate; do
curl --compressed "https://dashboard.iatistandard.org/stats/${f}.json" > stats-calculated/${f}.json
done
mkdir stats-blacklist
cd stats-blacklist
wget "http://dashboard.iatistandard.org/stats-blacklist/current.tar.gz" -O current.tar.gz
wget "http://dashboard.iatistandard.org/stats-blacklist/gitaggregate-dated.tar.gz" -O gitaggregate-dated.tar.gz
wget "http://dashboard.iatistandard.org/stats-blacklist/gitaggregate-publisher-dated.tar.gz" -O gitaggregate-publisher-dated.tar.gz
tar -xf current.tar.gz
tar -xf gitaggregate-dated.tar.gz
tar -xf gitaggregate-publisher-dated.tar.gz
cd ..
cd stats-calculated
wget "http://dashboard.iatistandard.org/stats/current.tar.gz" -O current.tar.gz
wget "http://dashboard.iatistandard.org/stats/gitaggregate-dated.tar.gz" -O gitaggregate-dated.tar.gz
wget "http://dashboard.iatistandard.org/stats/gitaggregate-publisher-dated.tar.gz" -O gitaggregate-publisher-dated.tar.gz
tar -xf current.tar.gz
tar -xf gitaggregate-dated.tar.gz
tar -xf gitaggregate-publisher-dated.tar.gz