I think there might be some terminology-related confusion here. If you check out a repository using svn checkout
, what you have is not a repository. It is a working copy. You can't do repository operations (like commit
or branch
) to a working copy, only to a repository.
If you are trying to test hook scripts, you need to first set up a repository on your local machine. You can either make your local repo act as a mirror of the "real" repo, or you can seed your local repo using a copy of your data. To do the latter, the procedure looks something like this:
- Use
svn export
to grab a snapshot of your "real" repo. Using export
instead of checkout
is important, since export
will not create the Subversion metadata folders that are normally present (this is important).
- Use
svn import
to load this tree into your local repository.
This will result in the HEAD of your local repository looking exactly like the HEAD of your "real" repo. Your local repo won't have the full history since it's not a complete mirror, but it will have the same file and folder layout. Most of the time, this is sufficient for the purposes of testing scripts.