allen213
allen213

Reputation: 2277

How do I output the difference between two specific revisions in Subversion?

I'm using Subversion via the Linux command line interface.

I want to see the difference between revision 11390 and 8979 of a specific file called fSupplierModel.php in my terminal. How can I do that?

Upvotes: 132

Views: 175922

Answers (2)

ahnbizcad
ahnbizcad

Reputation: 10797

To compare entire revisions, it's simply:

svn diff -r 8979:11390


If you want to compare the last committed state against your currently saved working files, you can use convenience keywords:

svn diff -r PREV:HEAD

(Note, without anything specified afterwards, all files in the specified revisions are compared.)


You can compare a specific file if you add the file path afterwards:

svn diff -r 8979:HEAD /path/to/my/file.php

Upvotes: 68

D'Arcy Rittich
D'Arcy Rittich

Reputation: 171351

See svn diff in the manual:

svn diff -r 8979:11390 http://svn.collab.net/repos/svn/trunk/fSupplierModel.php

Upvotes: 188

Related Questions