forked from sstangl/openpowerlifting
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
129 lines (118 loc) · 4.14 KB
/
Makefile
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
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
.PHONY: builddir csvfile check probe
DATADIR := meet-data
BUILDDIR := build
PLFILE := openpowerlifting.csv
PLFILEJS := openpowerlifting.js
MEETFILE := meets.csv
MEETFILEJS := meets.js
all: csvfile web
builddir:
mkdir -p '${BUILDDIR}'
# Cram all the data into a single, huge CSV file.
csvfile: builddir
scripts/compile "${BUILDDIR}" "${DATADIR}" "lifter-data"
scripts/csv-bodyweight "${BUILDDIR}/${PLFILE}"
scripts/csv-wilks "${BUILDDIR}/${PLFILE}"
# Optionally build an SQLite3 version of the database.
sqlite: csvfile
scripts/prepare-for-sqlite
scripts/compile-sqlite
web: csvfile
$(MAKE) -C web
# Make sure that all the fields in the CSV files are in expected formats.
check:
tests/check-entries-csv
tests/check-meet-csv
tests/check-sex-consistency
tests/check-lifter-data
# List of probes for federations that should be fully up-to-date,
# or at least are quick to read and not filled with noise.
# Data showing up here should be immediately actionable.
probe-quick:
${DATADIR}/aau/aau-probe --quick || true
${DATADIR}/apa/apa-probe || true
${DATADIR}/apc/apc-probe --quick || true
${DATADIR}/apf/apf-probe --quick || true
${DATADIR}/bb/bb-probe || true
${DATADIR}/bp/bp-probe --quick || true
${DATADIR}/bp/bpu-probe --quick || true
${DATADIR}/capo/capo-probe --quick || true
${DATADIR}/commonwealthpf/commonwealthpf-probe || true
${DATADIR}/cpf/cpf-probe --quick || true
${DATADIR}/cpl/cpl-probe --quick || true
${DATADIR}/gpc-aus/gpc-aus-probe --quick || true
${DATADIR}/herc/herc-probe || true
${DATADIR}/ipa/ipa-probe --quick || true
${DATADIR}/irishpf/irishpf-probe || true
${DATADIR}/nasa/nasa-probe --quick || true
${DATADIR}/nipf/nipf-probe || true
${DATADIR}/oceaniapf/oceaniapf-probe --quick || true
${DATADIR}/pa/pa-probe --quick || true
${DATADIR}/rps/rps-probe || true
${DATADIR}/rupc/rupc-probe || true
${DATADIR}/scottishpl/scottishpl-probe --quick || true
${DATADIR}/spf/spf-probe || true
${DATADIR}/upa/upa-probe --quick || true
${DATADIR}/usapl/usapl-probe || true
${DATADIR}/usapl-archive/usapl-archive-probe --quick || true
${DATADIR}/uspa/uspa-probe || true
${DATADIR}/xpc/xpc-probe || true
${DATADIR}/wrpf-can/wrpf-can-probe --quick || true
# List of all probes.
probe:
${DATADIR}/aau/aau-probe || true
${DATADIR}/apa/apa-probe || true
${DATADIR}/apc/apc-probe || true
${DATADIR}/apf/apf-probe || true
${DATADIR}/bb/bb-probe || true
${DATADIR}/bp/bp-probe || true
${DATADIR}/bp/bpu-probe || true
${DATADIR}/capo/capo-probe || true
${DATADIR}/commonwealthpf/commonwealthpf-probe || true
${DATADIR}/cpf/cpf-probe || true
${DATADIR}/cpl/cpl-probe || true
${DATADIR}/epf/epf-probe || true
${DATADIR}/fesupo/fesupo-probe || true
${DATADIR}/fpo/fpo-probe || true
${DATADIR}/gpc-aus/gpc-aus-probe || true
${DATADIR}/herc/herc-probe || true
${DATADIR}/ipa/ipa-probe || true
${DATADIR}/ipf/ipf-probe || true
${DATADIR}/irishpf/irishpf-probe || true
${DATADIR}/napf/napf-probe || true
${DATADIR}/nasa/nasa-probe || true
${DATADIR}/nipf/nipf-probe || true
${DATADIR}/nsf/nsf-probe || true
${DATADIR}/oceaniapf/oceaniapf-probe || true
${DATADIR}/pa/pa-probe || true
${DATADIR}/raw/raw-probe || true
${DATADIR}/rps/rps-probe || true
${DATADIR}/rupc/rupc-probe || true
${DATADIR}/scottishpl/scottishpl-probe || true
${DATADIR}/spf/spf-probe || true
${DATADIR}/thspa/thspa-probe || true
${DATADIR}/upa/upa-probe || true
${DATADIR}/usapl/usapl-probe || true
${DATADIR}/usapl-archive/usapl-archive-probe || true
${DATADIR}/uspa/uspa-probe || true
${DATADIR}/wrpf/wrpf-probe || true
${DATADIR}/wrpf-can/wrpf-can-probe || true
${DATADIR}/xpc/xpc-probe || true
clean:
rm -rf '${BUILDDIR}'
rm -rf 'scripts/__pycache__'
rm -rf 'tests/__pycache__'
rm -rf '${DATADIR}/apf/__pycache__'
rm -rf '${DATADIR}/cpu/__pycache__'
rm -rf '${DATADIR}/ipf/__pycache__'
rm -rf '${DATADIR}/nasa/__pycache__'
rm -rf '${DATADIR}/nipf/__pycache__'
rm -rf '${DATADIR}/nsf/__pycache__'
rm -rf '${DATADIR}/pa/__pycache__'
rm -rf '${DATADIR}/rps/__pycache__'
rm -rf '${DATADIR}/spf/__pycache__'
rm -rf '${DATADIR}/thspa/__pycache__'
rm -rf '${DATADIR}/usapl/__pycache__'
rm -rf '${DATADIR}/wrpf/__pycache__'
$(MAKE) -C server clean
$(MAKE) -C web clean