tags:

views:

274

answers:

2

HI All,

When iam executing svn force command given below on some path, iam getting the below error Please do let me know how to resolve this issue Command:

set SVN_PATH=C:\main\test
svn lock [--force] "%SVN_PATH%" -m "lock before commit"

Error:

svn: 'C:\main\test\[--force]' is not under version control
A: 

You shouldn’t include the square brackets in the command, they are just to indicate that the --force argument is optional.

But why are you locking the repository?

Ciarán Walsh
Directory is under version control only. Iam copying the output generated from build to subversion Directory , then executing the force command on whole Directory. Next step is committing the directory to subversion.
soni
+2  A: 
svn lock [--force] "%SVN_PATH%" -m "lock before commit"

should be:

svn lock --force "%SVN_PATH%" -m "lock before commit"

The square brackets area documentation convention indicating optionality. But frankly, if you didn't know that I wonder if you understand why you might use the lock command.

anon
iam using lock because , what ever checking in to subersion are dll's. Checking build output to subversion is required for us becasue from here only we will deploy to our enviorments.
soni
I removed the square brackets still iam getting that error. Please do let me know how to fix that issue.
soni
But why do you need to lock before commit?
Hardcoded