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

Re: Undo Add and lost work

From: Stefan Küng <tortoisesvn_at_gmail.com>
Date: Tue, 22 Oct 2013 20:20:57 +0200

On 22.10.2013 15:59, Hans-Emil Skogh wrote:
> Hi all!
>
> Today a colleague lost some work when a file somewhat surprisingly
> disappeared. This is maybe not a bug per se, but still very
> unfortunate.
>
> What happened was the following: - A new file was created by copying
> (not svn-copy) an existing versioned file, and some work was done on
> the file. - Then realizing that it should have been an svn-copy, the
> "Repair copy" function was used to add the file to svn with the
> correct copy-from-relation. - Unfortunately the wrong copy from file
> was chosen, so he did an "Undo Add..." on the file to re-do the
> action, only to find that the file had been deleted and (since the
> recycle bin was disabled) his work lost.
>
> I would not assume that a command called "Undo Add..." ever under any
> circumstances would delete a file.
>
> Proposal: When using the "Undo Add"-command on a file with copy-from
> relations the behavior should be identically to when using it on a
> simply added file. That is, the SVN-status should become unversioned
> and otherwise the file should be untouched. Since the "Undo Add"
> command is using svn revert, I guess it would require TSVN to save
> and restore the file when the svn revert deletes it. But still I
> think it would be the sane thing to do, from a user perspective.

maybe the 'svn revert' command should change here as well? I'll ask on
the svn mailing list...

$ svn cp file1 file1_copy
$ echo testline >> file1_copy
$ svn revert file1_copy
--> modifications are lost because file is gone

>
> Also; I would suggest to remove the "..." from the "Undo Add..."
> command in this case, since no confirmation dialog is shown.

It depends: if a folder is selected, the revert dialog is shown.

Stefan

-- 
        ___
   oo  // \\      "De Chelonian Mobile"
  (_,\/ \_/ \     TortoiseSVN
    \ \_/_\_/>    The coolest interface to (Sub)version control
    /_/   \_\     http://tortoisesvn.net
------------------------------------------------------
http://tortoisesvn.tigris.org/ds/viewMessage.do?dsForumId=757&dsMessageId=3066852
To unsubscribe from this discussion, e-mail: [dev-unsubscribe_at_tortoisesvn.tigris.org].
Received on 2013-10-22 20:21:06 CEST

This is an archived mail posted to the TortoiseSVN Dev mailing list.

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