>Our process group in its infinite stupidity has dictated that we now >provide lines of code for changes, but we must also provide new lines vs >changes lines, and of course did not provide any kind of tool that >would do this. My present project is a very Ada program which seems to always >be changing. Is there any kind of tool that would work on a PC, SUN, or VAX >that could provide the numbers or are we destined to try to do this by >hand? Here's a unix script I built a while back that seems to do (part of) what you want. It presumes you can execute the program count_ada_statements that measures SLOC's on a syntactically correct Ada program. (count_ada_statements is an Ada program that was written by Whittaker quite a few years ago. It's available on the PAL and on the Ada CD, among other places. The version I run is slightly modified to correct a miniscule error, but I think the public version is effective for the job at hand.) Here is a csh script that counts added and deleted lines: #! /bin/csh -f if ($#argv == 0) then echo "Give the up-to-date source file, and baseline for compare" else set new = $1 shift if ($#argv == 0) then echo "Comparing " $new "with what?" exit else set old = $1 echo "" echo " Comparing " $new "with " $old echo "" endif echo "Lines added to make " $new diff -biw $old $new | grep ">" | count_ada_statements echo "" echo "" echo "Lines removed to make " $new diff -biw $old $new | grep "<<" | count_ada_statements endif