source: trunk/Makefile @ 371

Last change on this file since 371 was 371, checked in by g7moreau, 6 years ago
  • Add stat target and update help one
File size: 2.7 KB
Line 
1DESTDIR=
2
3BINDIR=/usr/sbin
4MANDIR=/usr/share/man/man1
5SHAREDIR=/usr/share/klask
6LIBDIR=/usr/lib/klask
7CRONDIR=/etc/cron.d
8ETCDIR=/etc/klask
9COMPDIR=/etc/bash_completion.d
10
11.PHONY: all install update sync upload stat help
12
13all:
14        pod2man klask | gzip > klask.1.gz
15        pod2html klask > klask.html
16
17install: update
18        @install -d -m 0755 -o root -g root $(DESTDIR)/$(CRONDIR)
19        install    -m 0644 -o root -g root klask.cron $(DESTDIR)/$(CRONDIR)/klask
20
21update:
22        @install -d -m 0755 -o root -g root $(DESTDIR)/$(BINDIR)
23        install    -m 0755 -o root -g root klask $(DESTDIR)/$(BINDIR)
24
25        @install -d -m 0755 -o root -g root $(DESTDIR)/$(LIBDIR)
26        install    -m 0755 -o root -g root push-web $(DESTDIR)/$(LIBDIR)
27        install    -m 0755 -o root -g root klask-wrapper $(DESTDIR)/$(LIBDIR)
28
29        @install -d -m 0755 -o root -g root $(DESTDIR)/$(MANDIR)
30        install    -m 0644 -o root -g root klask.1.gz $(DESTDIR)/$(MANDIR)
31
32        @install -d -m 0755 -o root -g root $(DESTDIR)/$(SHAREDIR)
33        install    -m 0644 -o root -g root sorttable-klask.js $(DESTDIR)/$(SHAREDIR)
34        install    -m 0644 -o root -g root style-klask.css $(DESTDIR)/$(SHAREDIR)
35
36        @install -d -m 0755 -o root -g root $(DESTDIR)/$(ETCDIR)
37        install    -m 0644 -o root -g root klask-sample.conf $(DESTDIR)/$(ETCDIR)
38        install    -m 0644 -o root -g root push-web-sample.conf $(DESTDIR)/$(ETCDIR)
39
40        @install -d -m 0755 -o root -g root $(DESTDIR)/$(COMPDIR)
41        install    -m 0644 -o root -g root klask.bash_completion $(DESTDIR)/$(COMPDIR)/klask
42
43sync:
44        svn update
45
46upload:
47        cadaver --rcfile=cadaverrc
48
49stat:
50        svn log|egrep '^r[[:digit:]]'|egrep -v '^r1[[:space:]]'|awk '{print $$3}'|sort|uniq -c                 |gnuplot -p -e 'set style fill solid 1.00 border 0; set style histogram; set style data histogram; set xtics rotate by 0; set style line 7 linetype 0 linecolor rgb "#222222"; set grid ytics linestyle 7; set xlabel "User contributor" font "bold"; set ylabel "Number of commit" font "bold"; plot "/dev/stdin" using 1:xticlabels(2) title "commit" linecolor rgb "#666666"'
51        (echo '0 2015'; svn log|egrep '^r[[:digit:]]'|awk '{print $$5}'|cut -f 1 -d '-'|sort|uniq -c)|sort -k 2|gnuplot -p -e 'set style fill solid 1.00 border 0; set style histogram; set style data histogram; set xtics rotate by 0; set style line 7 linetype 0 linecolor rgb "#222222"; set grid ytics linestyle 7; set xlabel "Year"             font "bold"; set ylabel "Number of commit" font "bold"; plot "/dev/stdin" using 1:xticlabels(2) title "commit" linecolor rgb "#666666"'
52
53help:
54        @echo "Possibles targets:"
55        @echo " * all     : make manual"
56        @echo " * install : complete install"
57        @echo " * update  : update install (do not update cron file)"
58        @echo " * sync    : sync with official repository"
59        @echo " * upload  : upload on public dav forge space"
60        @echo " * stat    : svn stat with gnuplot graph"
Note: See TracBrowser for help on using the repository browser.