]> rtime.felk.cvut.cz Git - eurobot/public.git/blob - build/_infrastructure/commit-graph.pl
aa7503e670736047e0257fc222e45b8b81908862
[eurobot/public.git] / build / _infrastructure / commit-graph.pl
1 #!/usr/bin/perl -w
2
3 open GNUPLOT, "|gnuplot -persist";
4 print GNUPLOT <<EOF;
5 set xdata time
6 set timefmt "%s"
7 set format x "%m/%y" 
8 set xlabel "Date"
9 set ylabel "Commit number"
10 set grid
11 set key left top
12 EOF
13 %authors = ('Michal' => 'sojka',
14             'Martin' => '\(zidek\|mzi\)',
15             'Filip'  => 'jares',
16             'Jarda'  => 'jarin',
17             'Jirka'  => '\(jirka\|kubia\)',
18             'Marek'  => 'marek',
19             'Petr'   => 'benes',
20             "Celkem" => '.');
21 @plots = ();
22 foreach $author(sort keys %authors) {
23         push @plots, qq/'-' using 1:2 with linespoints title "$author"/;
24 }
25 print GNUPLOT "plot ", join(", ", @plots), ";\n";
26 foreach $author(sort keys %authors) {
27         @commits = `git log ace04654c8f2e11077c12ccf48d09fbb3bec28f3..HEAD --pretty=format:"%ct" --author='$authors{$author}'|sort -n`;
28         $i = 1;
29         foreach (@commits) {
30             chop;
31             print GNUPLOT "$_ $i\n";
32             $i++;
33         }
34         print GNUPLOT "e\n";
35 }
36 #            set xdata time
37 #            set timefmt "%m/%d/%y"
38 #            set xrange ["03/21/95":"03/22/95"]
39 #            set format x "%m/%d"
40 #            set timefmt "%m/%d/%y %H:%M"
41 #            plot "data" using 1:3