directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From akaras...@apache.org
Subject svn commit: r151105 - incubator/directory/codesize.sh
Date Thu, 03 Feb 2005 02:49:17 GMT
Author: akarasulu
Date: Wed Feb  2 18:49:15 2005
New Revision: 151105

URL: http://svn.apache.org/viewcvs?view=rev&rev=151105
Log:
Patch from E. Leacharny: http://issues.apache.org/jira/browse/DIR-99

Modified:
    incubator/directory/codesize.sh

Modified: incubator/directory/codesize.sh
URL: http://svn.apache.org/viewcvs/incubator/directory/codesize.sh?view=diff&r1=151104&r2=151105
==============================================================================
--- incubator/directory/codesize.sh (original)
+++ incubator/directory/codesize.sh Wed Feb  2 18:49:15 2005
@@ -7,14 +7,9 @@
            	continue;
         fi;
 
-	mkdir temp
-    	for file in `find $trunk -type f -regex '.*\.java'`; do
-    		cp $file temp;
-        done;
-        cd temp;
-        lines=`wc -l * | grep total | awk '{print $1}'`;
-        cd ../
-        rm -rf temp;
+        lines=$(for file in $(find $trunk -type f -name "*.java"); do wc -l $file; done |
awk '{sum += $col} END {print sum}')
+
+
         echo "lines of code in $trunk = $lines";
         total=$(($lines + $total));
 done;



Mime
View raw message