You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@subversion.apache.org by "Langel, Frank" <fl...@caxton.com> on 2008/10/01 21:03:22 UTC

Restore of directory from repository does not remove local, unversioned file

1. We are using svn 1.4 and checked in a directory ./test1 using
 
    svn copy <path>   <path>/tags/1.0/
 
    to tag this directory
 
2. On the working copy, I am now adding a file ./test1/notwanted.txt to
the directory
 
3. I am now trying to revert back the directory to it's previous state,
i.e. without the notwanted.txt file in the ./test1/ directory
 
I tried 
- svn update ./td1
- svn checkout <path>/tags/1.0/
- svn cp <path>/tags/1.0/test1 ./test1
 
without luck. Any idea?
 
Why doesn't SVN remove the unversioned notwanted.txt file ?
 
Thanks a lot
Frank
 
 
 
 
This message may contain information that is confidential or privileged. 
If you are not the intended recipient, please advise the sender immediately
and delete this message.

RE: RE: Re: Restore of directory from repository does not remove local, unversioned file

Posted by Pa...@Dell.com.
>> From: Ryan Schmidt [mailto:subversion-2008c@ryandesign.com] 
>> 
>> Subversion will not remove unversioned files; that would be 
>> data loss, which Subversion is specifically designed to prevent.
>
>except in the case where user A deletes and re-adds the same name
>file(s) in a branch, then merges his changes into the trunk
>
>user B is editing said files in the trunk, not yet committed, 'svn up'
>and poof -- data loss!!

A simpler/more common scenario is a modify on branch A and a rename on branch B, merge B to A and you'll lose the modify.

I mentioned this a while ago, and it turned out to be a bug known since before V1.0.  I also proposed a possible approach for a fix, but unfortunately there has been no feedback on that at all.  (Maybe it needs to be posted to svn-dev instead?)

	paul

RE: Re: Restore of directory from repository does not remove local, unversioned file

Posted by DW Dennis Wheeler <dw...@ag.com>.
 > -----Original Message-----
> From: Ryan Schmidt [mailto:subversion-2008c@ryandesign.com] 
> 


> 
> Subversion will not remove unversioned files; that would be 
> data loss, which Subversion is specifically designed to prevent.
> 

except in the case where user A deletes and re-adds the same name
file(s) in a branch, then merges his changes into the trunk

user B is editing said files in the trunk, not yet committed, 'svn up'
and poof -- data loss!!


but that's another subject

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


RE: Restore of directory from repository does not remove local, unversioned file

Posted by "Langel, Frank" <fl...@caxton.com>.
Thank you Ryan. Appreciate it, this was helpful. 

To summarize for all of us : Subversion will never remove unversioned
files. 


-----Original Message-----
From: Ryan Schmidt [mailto:subversion-2008c@ryandesign.com] 
Sent: Thursday, October 02, 2008 12:37 AM
To: Langel, Frank
Cc: users@subversion.tigris.org
Subject: Re: Restore of directory from repository does not remove local,
unversioned file

On Oct 1, 2008, at 4:03 PM, Langel, Frank wrote:

> 1. We are using svn 1.4 and checked in a directory ./test1 using
>
>     svn copy <path>   <path>/tags/1.0/
>
>     to tag this directory
>
> 2. On the working copy, I am now adding a file ./test1/ notwanted.txt 
> to the directory
>
> 3. I am now trying to revert back the directory to it's previous 
> state, i.e. without the notwanted.txt file in the ./test1/ directory
>
> I tried
> - svn update ./td1

What is ./td1?

> - svn checkout <path>/tags/1.0/
> - svn cp <path>/tags/1.0/test1 ./test1

You don't want either of those...

> without luck. Any idea?
>
> Why doesn't SVN remove the unversioned notwanted.txt file ?


Subversion will not remove unversioned files; that would be data loss,
which Subversion is specifically designed to prevent.

I think what you should do is run "svn status" to see which files are
unversioned, and if you do not want them anymore, then remove them.
 
 
 
 

This message may contain information that is confidential or privileged.  
If you are not the intended recipient, please advise the sender immediately
and delete this message.

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


Re: Restore of directory from repository does not remove local, unversioned file

Posted by Ryan Schmidt <su...@ryandesign.com>.
On Oct 1, 2008, at 4:03 PM, Langel, Frank wrote:

> 1. We are using svn 1.4 and checked in a directory ./test1 using
>
>     svn copy <path>   <path>/tags/1.0/
>
>     to tag this directory
>
> 2. On the working copy, I am now adding a file ./test1/ 
> notwanted.txt to the directory
>
> 3. I am now trying to revert back the directory to it's previous  
> state, i.e. without the notwanted.txt file in the ./test1/ directory
>
> I tried
> - svn update ./td1

What is ./td1?

> - svn checkout <path>/tags/1.0/
> - svn cp <path>/tags/1.0/test1 ./test1

You don't want either of those...

> without luck. Any idea?
>
> Why doesn't SVN remove the unversioned notwanted.txt file ?


Subversion will not remove unversioned files; that would be data  
loss, which Subversion is specifically designed to prevent.

I think what you should do is run "svn status" to see which files are  
unversioned, and if you do not want them anymore, then remove them.


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