You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@subversion.apache.org by "Marcel Molina Jr." <ma...@vernix.org> on 2004/06/09 17:10:40 UTC

symlinks cause 'svn add' to abort

i know that most of you are busy with finishing up 1.1 and getting it
out the door and i wish you best of luck with that and am cheering you
on, as it were...

despite that i was wondering if you all had time to answer a question i
had.

(in the event that it matters, i am using svn version 1.0.0 on debian
stable)

when doing 'svn add *' in a directory under which there are symlinks,
at the point at which svn arrives at a symlink it just quits with
"svn: Unsupported node kind for path '<path>'", despite there being
potentially many suitable candidates for adding.

not knowing all of the implications, i think, "it would be nice if it
emitted the warning, skipped that file or directory (and everything
beneath it if applicable) and kept going along". i wouldn't be inclined to
care one way or the other if my current work around were less undesirable.
i could either commit everything (if it's a new repo i can svn revert *)
and then do some sort of gnarly combination of:

svn st | grep -e ^?| awk '{print $2}'

and 

find -type l

and 

grep -v

and then wrap 'svn add' around all that.

questions:
    * what are the reasons for having 'svn add' abort rather than skip?
    * is there a better way of dealing with this than the way i am dealing
      with it (assume that the response "yeah, get rid of the symlinks" is
      not an option in my case).
    * if changing the behavior to skip rather than abort is on the menu, how
      high or low on the menu is it (if you know more or less, estimates are
      fun to have, if not particularly reliable)

googling for 'svn add symlink' returned some things such as:
http://www.contactor.se/~dast/svnusers/archive-2003-08/0248.shtml

but i don't know *why* it aborts nor did i find a less kludgy way of working
around it.

i suspect that setting properties and using an "ignore list" would probably
be somewhere in the ballpark of the answer...though i don't know what
specific aspect of those things apply to this situation...(still learning)

just to mention it, i *have* read the entire subversion book though i might
have missed it if there is an answer in there. please advise.

it was indicated to me that actually supporting symlinks altogether was a way
off if at all so i am basing those questions off the assumption that full on
symlink support is not going to come along and make all these questions moot.

thanks for you time and committed, good work,
marcel
-- 
Marcel Molina Jr. <ma...@vernix.org>

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Re: symlinks cause 'svn add' to abort

Posted by "C. Michael Pilato" <cm...@collab.net>.
"Marcel Molina Jr." <ma...@vernix.org> writes:

> not knowing all of the implications, i think, "it would be nice if it
> emitted the warning, skipped that file or directory (and everything
> beneath it if applicable) and kept going along".

And I tend to agree with you.  Myself, sussman, and kfogel had a
conversion about a similar situation with 'svn add' that was causing
folks grief (where one of the targets expanded by '*' is already
versioned -- see Issue #939).  It's an odd UI situation to be it.  Say
I have a directory, versioned, with two unversioned things in it: a
file 'File', and a symlink 'Link'.

Now, keep in mind that Subversion never sees that '*' -- the shell
expands that into a list of arguments before handing it off to
Subversion.

So If I type 'svn add *', that's exactly the same as typing 'svn add
File Link'.  Now, I'd like File to be added and Link to not cause a
fatal error (in case it gets hit first).  But what should the returned
error code/state be?  Clearly what I asked for wasn't accomplished in
full.

What about 'svn add Link'.  Should that warn, or error?  If warn, then
exactly what kinds of problem *should* cause errors?

> questions:
>     * what are the reasons for having 'svn add' abort rather than skip?

Likely it was just an oversight.

>     * is there a better way of dealing with this than the way i am dealing
>       with it (assume that the response "yeah, get rid of the symlinks" is
>       not an option in my case).

No.

>     * if changing the behavior to skip rather than abort is on the menu, how
>       high or low on the menu is it (if you know more or less, estimates are
>       fun to have, if not particularly reliable)

If we treat this the same as issue #939, then it's under consideration
for the current 1.1 milestone, but might get dozed until 1.2.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org