X-Git-Url: http://git.osdn.net/view?a=blobdiff_plain;f=untrans-list.pl;h=6ae2a2176a8bdb971e2ed3679a3bf38ae612595c;hb=af2a5f61bb3a4971ae9c71936257887bdb9bbf83;hp=6c169bd09dff1f2f421f1874678285451e332c05;hpb=14bc0078b395729492b319318b1f32f3d4c6e3a6;p=linuxjm%2FLDP_man-pages.git diff --git a/untrans-list.pl b/untrans-list.pl index 6c169bd0..6ae2a217 100755 --- a/untrans-list.pl +++ b/untrans-list.pl @@ -1,14 +1,55 @@ #!/usr/bin/env perl -print < -Translation status of LDP man-pages +Translation status of LDP man-pages + + + + EOF +} + +sub print_footer { + print < + +EOF +} + +sub print_poname { + my $poname = shift; + printf("\n", $poname); +} + +sub print_manpage { + my ($page, $all, $remaining, $ratio) = @_; + if ($ratio >= 80) { + print ''; + } elsif ($ratio >= 70) { + print ''; + } else { + print ''; + } + printf("", + $page, $remaining, $all, $ratio); + print "\n"; +} $poname = ""; +$poname_print = 1; + +print_header(); while (<>) { if (/^po4a/) { @@ -17,8 +58,7 @@ while (<>) { @dat = split('/', $cfg); $poname = $dat[2]; $poname =~ s/\.cfg$//; - printf("\n", $poname); + $poname_print = 1; } next if ! /^Discard /; s/\(//; @@ -28,12 +68,11 @@ while (<>) { $comp = $dat[2]; $all = $dat[4]; $ratio = $comp/$all*100; - #printf("%s: %d/%d, %.2f\n", $page, $comp, $all, $comp/$all*100); - printf("\n", - $page, ($all - $comp), $all, $ratio); + if ($poname_print) { + print_poname($poname); + $poname_print = 0; + } + print_manpage($page, $all, $all - $comp, $ratio); } -print < - -EOF +print_footer();
Released pages but not completed (released if >=80%)
Near release pages (>= 70%)
page nameremainingcomp. %
" . + "%s
%s%d/%d%.2f
" . - "%s
%s%d/%d%.2f