Subversionversion?

What version of subversion have I got? It depends. What do you mean?

Servers, clients and working copies all have versions associated with them.

(1) Server version

This question is answered in essentially the same as is (3a), but you’ll need access to the server machine.

Alternatively, if your repository is served by Apache, then type the URL (http://…) into your browser, and the version should be displayed on the page.

(2) Repository version

As with (1), you will need access to the server machine.

Take a look at the following files in your repository directory:

./format
./db/format
./db/fs-type

The following is a table containing some possible values of these files (i.e. their contents). Unfortunately, the table is not complete.

format db/format db/fs-type svn version
3 ? ? 1.0 – 1.3
5 2 fsfs 1.4
3 fsfs 1.5
4 fsfs 1.6

The values in this table are taken from the SVN source files

http://svn.collab.net/repos/svn/trunk/subversion/libsvn_repos/repos.h
http://svn.collab.net/repos/svn/trunk/subversion/libsvn_fs_fs/fs.h

Note that the two format values above are independent, and the latter is associated only with a file-system type data store (rather than, for example, the database type data store).

(3a) Client version (command line SVN)

To find out what client you’re running, simply type

svn --version

at the command line.

(3b) Client version (TortoiseSVN)

Simply look at

TortoiseSVN | about

from the context menu. Note that there’s both the version of TortoiseSVN itself, and the version of Subversion that it’s built against.

(4) Working copy version

Take a look at the following file(s) in (the hidden subdirectory <.svn> of) your repository directory:

./.svn/format

The following is a table containing some possible values of this file (i.e. its contents). Unfortunately, the table is not complete.

format svn version
4 1.0 – 1.3
8 1.4
9 1.5
10 1.6

The values in this table are taken from the SVN source file

http://svn.collab.net/repos/svn/trunk/subversion/libsvn_wc/wc.h

(5) Revisions

This is just basic usage: part of the basic work cycle.

If you want to know which version of a particular file you have, then relevant information is given with the following selection of commands.

What revision of a file do I have? And, have I changed the file?

svn st file-path
svn st -v file-path
svn status --verbose file-path

Is a file out of date; that is, has someone else change it in the repository?

svn st -u file-path
svn st -uv file-path
svn status --show-updates --verbose file-path

Get some general information on a file:

svn info file-path

Alternatively, an overview may be obtained with

svnversion
svnversion directory-path
Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s


%d bloggers like this: