Uploaded image for project: 'Subversion'
  1. Subversion
  2. SVN-3101

svn revert should provide a way to delete copied files

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 1.4.x
    • 1.7.0
    • libsvn_wc
    • None

    Description

      When you merge revisions who adds files. Those added files are flaged with "A+".
      When calling svn revert those files are unflaged but there is no way to
      automatically delete them since they havn't changed after the copy.
      
      Step to reproduce:
      flgu@oslo:/tmp$ svnadmin create testrepo
      flgu@oslo:/tmp$ svn co file:///tmp/testrepo testwc
      Checked out revision 0.
      cdflgu@oslo:/tmp$ cd testwc
      flgu@oslo:/tmp/testwc$ touch a
      flgu@oslo:/tmp/testwc$ svn add a
      A         a
      flgu@oslo:/tmp/testwc$ svn commit -m "add a"
      Adding         a
      Transmitting file data .
      Committed revision 1.
      flgu@oslo:/tmp/testwc$ mkdir b
      flgu@oslo:/tmp/testwc$ svn add b
      A         b
      flgu@oslo:/tmp/testwc$ svn commit -m "add directory b"
      Adding         b
      
      Committed revision 2.
      flgu@oslo:/tmp/testwc$ cd b
      flgu@oslo:/tmp/testwc/b$ svn merge -c 1 file:///tmp/testrepo .
      A    a
      flgu@oslo:/tmp/testwc/b$ svn stat
      A  +   a
      flgu@oslo:/tmp/testwc/b$ svn revert -R .
      Reverted 'a'
      flgu@oslo:/tmp/testwc/b$ ls -l
      total 0
      -rw-r--r-- 1 flgu flgu 0 Feb 15 10:55 a
      flgu@oslo:/tmp/testwc/b$
      
      An option like --safe-delete to svn revert would be great.
      

      Original issue reported by flyer

      Attachments

        Activity

          People

            Unassigned Unassigned
            subversion-importer Subversion Importer
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: