Sunday, March 28, 2010

SVN Ignore

Okay... Spring's here, no more snow, I've gotten out of the house two weekend's in a row. Time to get back to work.

I keep forgetting how to tell SVN to ignore a directory. This is a big deal for me, since I have a habit of creating working directories outside of my server's web root, then moving the files once they are validated. It's a security thing, but it means my dev serves always have allot of dead files laying around. Here's how to ignore the working directories.

First, ensure your EDITOR environmental variable is set:
export EDITOR=vi
(Add this to your ~/bash_profile if needed.)

From SVN root, execute:
svn propedit svn:ignore ./target/dir
This should toss you into the editor. Add the appropriate bash style wildcards representing file names and types. For my, a simple * (asterisk) usually suffices. Save the file, and run and svn status to verify the results.

No comments:

Post a Comment