[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: Including instead of ignoring files

From: Ryan Schmidt <subversion-2005_at_ryandesign.com>
Date: 2005-10-08 15:24:25 CEST

On Oct 8, 2005, at 13:32, Kynn at Panix wrote:

>> How about setting
>> svn:ignore = *
>> ...
>> You can set that in your ~/.subversion/config file.
> What exactly do you mean? I tried putting
> svn:ignore = *
> in my ~/.subversion/config file and I got an error:
> svnadmin: /home/kynn/.subversion/config:1: Section header expected

You do need an appropriate section header before that, as you tried

> I tried other alternatives, which silenced the error, but were
> ineffective, meaning that imports still caused all the files in the
> current directory to be imported.
> For example, after putting this in my ~/.subversion/config file:
> ### Start
> [miscellany]
> enable-auto-props = yes
> [auto-props]
> * = svn:ignore=*
> ### End
> I tried
> % rm -rf ~/dummy-repos dummy
> % svnadmin create ~/dummy-repos
> % mkdir dummy
> % cd dummy
> % touch foo bar baz
> % svn import . file:///home/kynn/dummy-repos/dummy -m 'no message'
> Adding foo
> Adding bar
> Adding baz
> Committed revision 1.
> As you can see, everything in the current directory got imported; the
> lines in my ~/.subversion/config file did not have the intended
> effect.

I think trying to set svn:ignore may have been the wrong advice,
since auto-props only work for files, but you would need to set the
svn:ignore property of directories. You could set svn:ignore = * on
each directory in your project manually and commit that, but that
would probably be a pain, as you'd have to remember to do it for each
new directory you create. Making auto-props work for directories is
an open feature request:


How about instead setting global-ignores? With this in my config file:

global-ignores = *

I get the result that I think you want:

$ svnadmin create /tmp/repo
$ mkdir /tmp/import
$ cd /tmp/import
$ touch foo bar baz
$ svn import . file:///tmp/repo -m ""
$ svn ls file:///tmp/repo

Nothing gets imported. Everything gets ignored. The same would apply
to svn add and svn status.

I was going to tell you that it would still be easy to import a
project initially, since you could pass the --no-ignore option to svn
import, but I had some trouble getting that to work, and sent a
separate message to the list about that.

To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Received on Sat Oct 8 15:26:03 2005

This is an archived mail posted to the Subversion Users mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.