On Aug 30, 2010, at 12:50, Tech Geek wrote: > I am just getting started with SVN and I am running the latest version of > subversion on a Windows Server. I am looking for a pre-commit.bat hook that > will check for presence of a particular file (say project.xml) before > commiting to the repository. If the working copy that is about to be > committed does not have that file then the commits are rejected else the > commits are accepted. > > I tried looking into svnlook command but not sure how to that command to look > for a particular file.
Subversion hook scripts run on the server, not the client, so they have no knowledge of the user's working copy. So there's no way to do what you want using Subversion's server-side hook scripts. > I am using TortoiseSVN client. I believe TortoiseSVN has client-side hook scripts that are separate from Subversion's server-side hook scripts. Perhaps you can do what you want that way. Even if you could, that would require all your users to use TortoiseSVN, and they could simply bypass the restriction by using another client.