Search code examples
svn

Base version of an ignored file in SVN


Currently I know that there is a way in SVN to not check in a file at all (or remove it from the repository) and then put it to ignore list.

Is it possible to have a "base" version of a file under its final name (not the renamed one) in SVN and then ignore all local changes made by any developer?


Solution

  • No. The file is either ignored or not. Since the file was already added into Subversion, adding its name or name pattern to svn:ignore won't make SVN ignore local modifications of the file.

    The svn:ignore and global ignores do not affect versioned files (that have been already added into the repository).

    However, if you are using TortoiseSVN, perhaps the ignore-on-commit changelist will help you:

    Any file added to this changelist will automatically be unchecked in the commit dialog. You can still commit changes, but you have to select it manually in the commit dialog.

    Also see this thread.