1

I'd like to find out what has changed between versions of a large project such as Mozilla-Firefox, i.e. similar to the question but must work on Linux and is open-source. I'm aware of Source Code Diff / Line and File Comparison which is Windows based.

I currently have two large tarballs of the actual released version of Firefox 5.0 and 6.0 which I have extracted into two folders mozilla-release-5.0/ and mozilla-release-6.0/

I'd like to see similar summary information for the diff of the two source trees, i.e.

• # of LINES added / removed / modified • # of FILES added / removed / modified

Ideally these figures are for lines of source code and blank lines etc. are ignored.

Note that as this is for statistical analysis, I don't care about the actual lines themselves and I am only interested in the summary figures.

Community
  • 1
  • 1
Sean
  • 3,765
  • 3
  • 26
  • 48

2 Answers2

1

To get the histogram that for example git diff --stat produces for submissions, you can use "diffstat" - although it doesn't appear to be able to distinguis empty line changes.

Mats Petersson
  • 126,704
  • 14
  • 140
  • 227
  • Sorry I should have clarified that I have a number of release tarballs which I have extracted rather than an SCM. Would it be simplest to load it all into `git` and do this? I've never used `git`. – Sean Jan 10 '13 at 10:24
  • 1
    No, if you have two tarballs, you uncompress the tarballs into a directory each (e.g. dirv1 and dirv2), do `diff -r dirv1 dirv2|diffstat` and it will tell you in a nice histogram how many lines have changed in each file. – Mats Petersson Jan 10 '13 at 21:04
0

Try also pkgdiff to visualize differences between directories or packages.

Diff directories:

pkgdiff -d DIR-0/ DIR-1/

Diff packages:

pkgdiff PKG-0.tgz PKG-1.tgz

enter image description here

enter image description here

linuxbuild
  • 15,843
  • 6
  • 60
  • 87