95

I ignored a file in TortoiseSVN by mistake. How do I reverse this and add the file to my repository?

6 Answers 6

124

Just edit the svn:ignore property (in the subversion tab of the directory properties). (If you ignored a subfolder, select the property tab of it's parent folder)

2
  • 6
    Might be worth to take a look in svn:globalignore property, too Commented Oct 10, 2014 at 14:45
  • 1
    Also look at the same tab in subfolders if you can't find anything at root level
    – ccalboni
    Commented Mar 28, 2018 at 10:30
19

If you right click on the directory containing the file and select SVN Properties, you should see an svn:ignore property with a list of ignored files. Simply edit that list and remove the rule ignoring your file.

1
  • 2
    The menu structure for me was right click on folder->TortoiseSVN->Properties. Thanks for the tip!
    – veeTrain
    Commented Jan 20, 2016 at 15:46
18

"Ignoring Files And Directories" from the Tortoise SVN documentation states:

If you want to remove one or more items from the ignore list, right click on those items and select TortoiseSVNRemove from Ignore List You can also access a folder's svn:ignore property directly. That allows you to specify more general patterns using filename globbing, described in the section below. Read the section called “Project Settings” for more information on setting properties directly. Please be aware that each ignore pattern has to be placed on a separate line. Separating them by spaces does not work.

5

For me, the solution was to use "Update to Revision".

My ignored files had been set as ignored automatically when I did a checkout but had not put a checkmark by the files.

When I did Update to Revision, I verified that the files were to be included by going to "Chose Items..."

I was not able to find anything in the properties menu that listed ignored files (a la Gabriel's suggestion). In fact, the properties were empty.

1
  • That was my case (forgot checkmark at checkout) and "update to revision" worked, thanks!
    – Milo
    Commented Mar 4, 2013 at 16:42
1

In my case there was another problem: the global ignore list in tortoise Settings, General.

Tortoise ships by default with .so files in the ignore list and we store these in source control (yes I know this is far from ideal). Removing them from the list sorted it out for me.

-2

I usually just add the ignored file with Tortoise and don't bother to remove the entry from the ignore list. so far I had no negative side effect...

3
  • When the file is ignored, Add no longer shows up as an option in the TortoiseSVN menu Commented Aug 25, 2009 at 18:33
  • that is not what I experience. I checked the checkbox for the "add" command in the tortoise svn settings under context menu. this way the "add" command always appears directly in the explorer context menu. maybe this makes a difference? Commented Aug 26, 2009 at 7:17
  • I've made that change as well and I don't see it in the context menu for ignored directories.
    – Jammer
    Commented Aug 26, 2013 at 11:39

Not the answer you're looking for? Browse other questions tagged or ask your own question.