/[debconf-data]/penta/publish-data.sh
ViewVC logotype

Contents of /penta/publish-data.sh

Parent Directory Parent Directory | Revision Log Revision Log


Revision 2758 - (show annotations) (download) (as text)
Wed Jun 29 05:17:39 2011 UTC (22 months, 3 weeks ago) by rkd-guest
File MIME type: application/x-sh
File size: 2658 byte(s)
various uncommittend changes
1 #!/bin/bash
2
3 set -e
4 cd `dirname $0`
5 #export location=lefschetz:www/http/debconf/
6 export location=mire:www/rkd.zgib.net/http/debconf/
7
8 export WHERE=dcvn.attend
9 python public/registration-statistics.py > published-data/registration-data.txt
10 #python public/rooms-statistics.py > published-data/rooms-by-date.txt #obselete
11 python public/rooms-statistics2.py > published-data/rooms-by-date-2.txt
12 #python public/talks-statistics.py > published-data/talks-data.txt
13 python public/food-statistics.py > published-data/food-by-date.txt
14 #python public/payment-statistics.py > published-data/payment-data.txt
15 python public/budget-report.py > published-data/budget-report.txt
16 unset WHERE
17
18 for info in \
19 "only-all/ true conference_id=5" \
20 "only-attend/ dcvn.attend conference_id=5" \
21 "only-reconfirmed/ dcvn.attend and dcvn.reconfirmed conference_id=5" \
22 "only-arrived/ dcvn.attend and dcvn.reconfirmed and cp.arrived conference_id=5" \
23 ; do
24 prefix="`echo "$info" | cut -f 1`"
25 export WHERE="`echo "$info" | cut -f 2`"
26 #export CONFERENCE_ID=`echo "$info" | cut -f 3`
27 mkdir -p published-data/${prefix}
28
29 python public/registration-statistics.py > published-data/${prefix}registration-data.txt
30 # python public/payment-statistics.py > published-data/${prefix}payment-data.txt
31 python public/rooms-statistics2.py > published-data/${prefix}rooms-by-date-2.txt
32 python public/food-statistics.py > published-data/${prefix}food-by-date.txt
33 python public/budget-report.py > published-data/${prefix}budget-report.txt
34 unset prefix
35 unset WHERE
36 done
37
38 # For all conferences:
39 for info in \
40 "dc11- 5 conference_id=5" \
41 "dc10- 4 conference_id=4" \
42 "dc09- 3 conference_id=3" \
43 "dc08- 2 conference_id=2" \
44 "dc07- 1 conference_id=1" ; do
45 confprefix=`echo "$info" | cut -f 1`
46 export CONFERENCE_ID=`echo "$info" | cut -f 2`
47 export WHERE=`echo "$info" | cut -f 3`
48
49 python public/talks-statistics.py > published-data/${confprefix}talks-data.txt
50 done
51
52 # Accounting updates
53 LEDGER=../debconf-data/dc11/ledger-dc11
54
55 if [ -e $LEDGER ] ; then
56 cat > published-data/accounting-balances.txt <<EOF
57 Current balance sheet:
58
59 `ledger bal -f $LEDGER --no-color`
60
61
62
63 Current balance sheet, converted to EUR:
64
65 `ledger bal -f $LEDGER -X EUR --no-color`
66
67
68
69 Our current bank balances:
70
71 `ledger bal -f $LEDGER --no-color ^assets`
72
73
74
75 Our incomes so far:
76
77 `ledger bal -f $LEDGER --no-color ^incomes`
78
79
80
81 Our expenses so far:
82
83 `ledger bal -f $LEDGER --no-color ^expenses`
84
85 EOF
86 fi
87
88
89 rsync -raiv published-data/ $location
90
91 # this contains hidden filenames
92 test -e publish-private-dat.sh && sh publish-private-dat.sh
93

  ViewVC Help
Powered by ViewVC 1.1.5