Andy Levy wrote:
> On Thu, Jul 23, 2009 at 12:01, Parrish, Ken<KParrish_at_gomez.com> wrote:
>
>> I have been asked by my management to calculate the total number of lines
>> of code which were added or modified between two revisions in our source
>> code.
>>
>>
>>
>> Is there a way, using Subversion commands, to calculate such statistics?
>>
>
> Not purely with Subversion, you 'll need to script it. There are
> several scripts/packages that do this. On a simplistic level, you can
> either use the output of svn diff or export both revisions and run wc
> -l on each, then compare. But that doesn't account for binary files,
> entirely new files, files deleted, etc. And even a minor refactoring
> can skew those numbers heavily.
>
> But it's a losing proposition. Tracking development by statistics like
> this is a sign that management doesn't understand that building
> software is not like building a skyscraper. I had a PM (Princeton or
> Harvard MBA, no less) once who wanted me to estimate how many LOC my
> application would ultimately be, and then gauged my progress by asking
> for a LOC count weekly.
>
> ------------------------------------------------------
> http://subversion.tigris.org/ds/viewMessage.do?dsForumId=1065&dsMessageId=2374879
>
> To unsubscribe from this discussion, e-mail: [users-unsubscribe_at_subversion.tigris.org].
>
I just wanted to ask, if this is a measure of quality or what? It is
actually quite contrary to me. Anyway, I would rather spend my energy on
developing a correct measurement processes against (hopefully) defined
requirements, than blindly follow requests like this. Just be alert not
to become a gopher...
Anyway, if this was a quick one, I'd checkout two revs and use 'find' to
crawl with '-type f' and '-exec' option, then use 'file' to select text
files and then count lines with 'wc -l'. Maybe there are more
sophisticated tools that can do (Beyond Compare?), but I can't tell.
This is new to me.
R.
The information contained in this e-mail and in any attachments is confidential and is designated solely for the attention of the intended recipient(s). If you are not an intended recipient, you must not use, disclose, copy, distribute or retain this e-mail or any part thereof. If you have received this e-mail in error, please notify the sender by return e-mail and delete all copies of this e-mail from your computer system(s).
Please direct any additional queries to: communications_at_s3group.com.
Thank You.
Silicon and Software Systems Limited. Registered in Ireland no. 378073.
Registered Office: South County Business Park, Leopardstown, Dublin 18
------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=1065&dsMessageId=2374888
To unsubscribe from this discussion, e-mail: [users-unsubscribe_at_subversion.tigris.org].
Received on 2009-07-23 18:26:45 CEST