How do I svn:ignore with AnkhSVN?
Asked Answered
H

1

12

I understand Subversion/AnkhSVN very well at all! Any time I do anything outside of updating and committing, everything blows up in my face.

These are my beliefs -- which must be incorrect, because I can't get Ankh to ignore anything.

  1. svn:ignore is a tool to make your Subversion client always leave certain files or directories OUT of update and commit lists. So, whenever you change any file that's being ignored, Ankh will never try to commit the change nor will it ever update the file. It's essentially invisible to your Subversion client

  2. In order to ignore a file using AnkhSVN, you must

    • right click on the directory in which the file resides
    • select Subversion->Subversion Properties
    • add a new Subversion property with name 'svn:ignore' and in the values box I enter newline-delimited list of things like '*.log' in order to ignore everything file file extension .log in THAT directory.

My assumptions are most certainly incorrect as I've never ever been able to get svn:ignore to work for me. Can anyone please revert me back to sanity by explaining to me which of my assumptions are incorrect and how I'm supposed to approach this?

Hoag answered 19/11, 2010 at 1:18 Comment(0)
F
20

The first assumption is indeed wrong. svn:ignore only works for unversioned files, it keeps them from being added when you do a recursive add. It's most useful on the command line for that reason.

In AnkhSVN there's a much easier way to add files to the svn:ignore list. Right click any unversioned file and choose Subversion -> Ignore. Inside are options to ignore the single file, all files with the extension etc.

You can right click a changed/added file (hint: use View - Pending Changes to see them all) and click Subversion -> Move to Change List -> ignore-on-commit. This is a change list that AnkhSvn and TortoiseSvn to have the items deselected by default. You can still commit them when you explicitly select them though

Frustration answered 19/11, 2010 at 8:9 Comment(2)
thanks! so it looks like ignore-on-commit is the most important thing I needed. However, is there anything that I can do in order to prevent a file from being changed when i perform an Update?Hoag
Also, what is proper protocol for unversioning a file that is currently versioned?Hoag

© 2022 - 2024 — McMap. All rights reserved.