X-Git-Url: https://git.llucax.com/z.facultad/75.42/plaqui.git/blobdiff_plain/5be7519199498d5ab6364c875d54bc81078c062b..a5853e30ca27518a7a3a33e4f97588f7b1e9ffe3:/log_trace.pl diff --git a/log_trace.pl b/log_trace.pl index f1716d3..428893b 100755 --- a/log_trace.pl +++ b/log_trace.pl @@ -10,21 +10,47 @@ #@lines = ; #close(LOG); -$texto = `svn log | grep rev | grep lines`; +#$texto = `svn log | grep rev | grep lines`; +$texto = `cat log.txt | grep rev | grep lines`; @lines = split(/\n/, $texto); -my %hash; +my %hash, %users; foreach $line (@lines) { @datos = split(/ /, $line); $hash{$datos[5]}++; + $users{$datos[5]}{$datos[3]}++; } print "PlaQui - Grafica de Progreso SVN\n"; +print "--------------------------------\n\n"; +print "Fecha Commits\n"; + foreach $date (sort keys %hash) { - print "$date\t"; + print "$date "; + + $win = ""; + $win_pts = -1; + foreach $name (keys %{$users{$date}}) { + if ($users{$date}{$name} > $win_pts) { + $win = $name; + $win_pts = $users{$date}{$name}; + } else { + if ($users{$date}{$name} = $win_pts) { + $win = $win."|".$name; + } + } + } + + #Imprimo el Ganador + for($i=0; $i<$hash{$date}; $i++) { print "*"; } + print "($win)"; print "\n"; } +print "\n"; +print "( ) = Máximo Commiteador del Día\n"; +print "* == 1 Commit\n"; +