I'm trying to add the directory with a space in it:
Static Debug
to my SVN ignore pattern.
However, spaces are used to separate different directories (so the above ignore pattern would be interpreted as two files to ignore -- Static and Debug)
I've tried adding
Static%20Debug
and
"Static Debug"
and
Static\ Debug
with no luck
And apparently I can't ignore by regular expression.
Anyone have any idea?
You can ignore a file or directory like . gitignore. Just create a text file of list of directories/files you want to ignore and run the code below: svn propset svn:ignore -F ignorelist.
To ignore files in subversion you want to set the svn:ignore property. You can see more here http://svnbook.red-bean.com/en/1.8/svn.advanced.props.special.ignore.html about half way down. svn propset svn:ignore target . svn propedit svn:ignore .
This is a fast and easy way to remove all generated files in your working copy. All files and folders that are not versioned are moved to the trash bin. Note: you can also do the same from the TortoiseSVN → Revert dialog. There you also get a list of all the unversioned files and folders to select for removal.
I found this documentation in the tortoise manual. According to it
[...]
Matches any one of the characters enclosed in the square brackets. Within the brackets, a pair of characters separated by “-” matches any character lexically between the two. For example [AGm-p] matches any one of A, G, m, n, o or p.
So I can simply do
Static[ ]Debug
which works
Ok that actually DOESN'T WORK for whitespace in my version of Tortoise
What works is using
?
Matches any single character.
which lets me do
Static?Debug
which unfortunately also matches stuff like StaticADebug. But this is good enough to do the trick.
Related to Doug T.'s Answer, I played around with this a bit.
Instead of using ?, you can specify an exclusion range with [] by putting a ^ at the front.
ignore[^A-Za-z0-9]this
If I have an "ignore this" and a "ignore0this", the one with the space will be ignored, but not the one with the 0.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With