Get revision number of a remote repository

okoman picture okoman · Mar 8, 2009 · Viewed 21.7k times · Source

On the local machine it is no problem to get the revision number of a subversion repository with svnversion. Now I want to get the revision number from my online repository (WebDAV with Apache2).

I tried this:

svnversion http://nick:[email protected]/svn/test`

In a browser it worked as usual (just to ensure there weren't typos or so), but svnversion said that the directory cannot be found. So I presume I was on the wrong track.

How can I get the revision number?

Answer

Paul Dixon picture Paul Dixon · Mar 8, 2009

svnversion is just for working copies, but one way to query your repository would be to use svn info as follows:

svn info http://nick:[email protected]/svn | grep Revision