]> hydra-www.ietfng.org Git - grade/commitdiff
Suppress printout of (-N) in worthless sections
authorNathaniel Wesley Filardo <nwf@cs.jhu.edu>
Mon, 2 Mar 2015 23:49:55 +0000 (18:49 -0500)
committerNathaniel Wesley Filardo <nwf@cs.jhu.edu>
Mon, 2 Mar 2015 23:49:55 +0000 (18:49 -0500)
grade.pl

index 1a3a77f8f689ee498a6f26ba8e6b76f87f095316..737fe14ae2b25afb9098afb7e81d8a26ed0f3405 100755 (executable)
--- a/grade.pl
+++ b/grade.pl
@@ -93,7 +93,11 @@ sub doDing($) { # {{{
       } else {
         $dingsum += $1;
       }
-      push @$dingtext, "($1)";
+      # If the section has point value, label the deduction here
+      # with its value.  Zero-point sections don't merit the clutter.
+      if ($secmax != 0) {
+        push @$dingtext, "($1)";
+      }
       untilDefinesDot(sub ($) { push @$dingtext, @_; });
       push @$dingtext, "";
       return;