-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
90 lines (69 loc) · 1.75 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
# Makefile
# File ID: 3eaf2bda-20dd-11e4-a0e2-c80aa9e67bbd
.PHONY: default
default: README.html status
README.html: README.md
printf '<html><head><title>README</title></head><body>\n' >README.html
cmark -t html README.md >>README.html
printf '</body></html>\n' >>README.html
relative.dat: repos.dat repos.sqlite Makefile
./convert-to-relative repos.dat >relative.dat
repos.sql: repos.dat Makefile
./create-sql repos.dat >repos.sql
repos.sqlite: repos.sql Makefile
rm -f repos.sqlite
sqlite3 repos.sqlite <repos.sql
status.txt: repos.sqlite
./textreport >status.txt
graph/repos.svg: repos.dat Makefile
./plot-graph --svg repos.dat
graph/relative.svg: relative.dat Makefile
./plot-graph --svg relative.dat
graph/relative-zoom.svg: relative.dat Makefile
./plot-graph --svg --zoom relative.dat
.PHONY: abs
abs:
./plot-graph repos.dat
.PHONY: bezier
bezier: relative.dat
./plot-graph --bezier relative.dat
.PHONY: clean
clean:
rm -fv README.html relative.dat repos.sql repos.sqlite
rm -fv *.tmp
touch repos.dat
.PHONY: commit
commit: clean update status
git add repos.dat status.txt
git ci -m "$$( \
printf 'Updates from openhub.net\n\n%s\n\n%s' \
"$$(./new-since)" \
"$$(suuid -t commit)" \
)"
.PHONY: dups
dups:
cat repos.dat >>dups.dat
$(MAKE) sort
git checkout -f repos.dat
.PHONY: plot
plot: relative.dat
./plot-graph relative.dat
.PHONY: status
status: status.txt
cat status.txt
.PHONY: sort
sort:
sort -u repos.dat >repos.dat.tmp
mv repos.dat.tmp repos.dat
sort -u dups.dat >dups.dat.tmp
mv dups.dat.tmp dups.dat
.PHONY: svg
svg: graph/repos.svg graph/relative.svg graph/relative-zoom.svg
.PHONY: test
test:
.PHONY: update
update:
./get-new-stats.py
.PHONY: zoom
zoom: relative.dat
./plot-graph --zoom relative.dat