Reputation: 20936
We have the sources of a big project. Me with my colleague are working with just several files in this project and we do not want to put it all under the version control. Me and my colleague have local copies of the project on our machines. I modified and committed several files in my copy performing commands:
svn add --non-recursive folder1/folder2
svn add folder1/folder2/file1.txt
svn ci -m "Message"
After that my colleague update his project and receives the error:
svn: Failed to add directory 'folder': an unversioned directory of the same name already exists
Is it possible somehow to deal with this problem. We do not want to put the whole project under the version control.
Upvotes: 1
Views: 85
Reputation: 16605
Use svn up --force
. Here's a quote from svn up --help
:
If --force is used, unversioned obstructing paths in the working
copy do not automatically cause a failure if the update attempts to
add the same path. If the obstructing path is the same type (file
or directory) as the corresponding path in the repository it becomes
versioned but its contents are left 'as-is' in the working copy.
This means that an obstructing directory's unversioned children may
also obstruct and become versioned. For files, any content differences
between the obstruction and the repository are treated like a local
modification to the working copy. All properties from the repository
are applied to the obstructing path. Obstructing paths are reported
in the first column with code 'E'.
Upvotes: 1
Reputation: 3815
You can commit the trunk of your project and have svn ignore the files and folders that you do not want under version control.
this way all the files that you want to work collaboratively will be available and nothing more.
Upvotes: 1