Matteo Gatto
Matteo Gatto

Reputation: 626

SVN read-only repository

I work with Subversion and TortoiseSVN GUI. I need to block a repository (making it read-only) so that when I release a version no one can modify that repository. I create a new folder for every version I release.

Upvotes: 3

Views: 3588

Answers (2)

Jean-Rémy Revy
Jean-Rémy Revy

Reputation: 5677

The better way, IMHO, to do that is to :

  1. allow one person (or group, according to linux permission) to write in /tags path,
  2. deny to other account (or group) to write there, but give them read permission
  3. allow writing for everyone in /trunk and /branches.

Then, modify either pre-commit.pl script (see Subversion Repositories: Governing Commit Permissons, or modify access via Apache (here some examples : How to configure SVN web access for different write permissions?).

If you really want to tweak it easy, install a SVN Admin tool : SVN admin management GUI tool

In both cases, you won't be able to set tag in read only mode ... Indeed, you might success writing a perl script, a post-commit HOOK, which will lock the tag, but I'm pretty sure that's a bad idea.

Upvotes: 2

bahrep
bahrep

Reputation: 30662

Do you use dedicated Subversion server + Apache2 + ? or work just locally via 'file:///'?

Subversion works with Path-Based Authorization and it's really easy to set authorization rights. BTW if your Subversion server has admin GUI I think the task can be done in a couple of clicks.

Upvotes: 1

Related Questions