Thursday, September 11, 2014

Ignore a file (in committing) that is checked out with/within TortoiseSVN.

  1. The file to ignore will need a change to differentiate it from what is in source control. If you do not need to intentionally drift your file away from what is in source control (i.e. think your local Web.config) then you may need to put a superficial line break in the file. Otherwise, just change up your local version.
  2. Right-click on the topmost folder associated with what is checked out from Subversion and pick "SVN Commit..." from the menu which appears.
  3. A list of files to potentially commit will appear here and to ignore your file you should right-click upon it and then pick "ignore-on-commit" which is not immediately in the menu which appears but which may be found in the second menu that appears when you mouse over "Move to changelist" at the base of the menu which immediately appears.

This will do the trick. It will keep you from accidentally committing that thing that needs to stay out of sync with what is checked in. The "ignore-on-commit" list will appear in the same pane for committing and you may always click on your outlier file here and pick "Remove from changelist" to set its state back to committable. To actually commit you will either need to check the checkbox by the item or close the window and reenter it where you will see the checkbox checked by default.

No comments:

Post a Comment