Script to check if all files are under the same root SVN
HI guys,
i have this method of working with branches and some times what happens is that some of the files under my checked out directory point to the wrong ro开发者_C百科ot i.e they will be pointing to a file in one of the branch instead of the actual branch.
I was wondering if there is a script that can verify if all the files in my checked out folder are under the same root..
Thanks a lot in advance.
This should do the trick: Suppose the expected root is something like https://svn.server.local/trunk/
, execute the following in the local copy's root folder:
svn info -R | grep "URL:" | grep -v "URL: https://svn.server.local/trunk/"
Or, on Windows:
svn info -R | FIND "URL:" | FIND /V "URL: https://svn.server.local/trunk/"
The output will be the URL list of files not under the root repository.
精彩评论