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

property merging unnecessarily strict

    XMLWordPrintableJSON

    Details

    • Type: Improvement
    • Status: Open
    • Priority: Critical
    • Resolution: Unresolved
    • Affects Version/s: all
    • Fix Version/s: unscheduled
    • Component/s: libsvn_fs
    • Labels:
      None

      Description

      Committing a property change to a directory fails if that directory is out-of-date, even if it's only out-of-date due to bubble-up semantics. This can be a bit tiresome; from the user's point of view, why is the property change being prohibited? It's hard to justify.

      The shell script below demonstrates the problem.

      I think there's some reason we have this limitation – no theoretical showstopper, just ease of implementation or something like that. Might be time to reexamine the tradeoff, though.

      ============= cut here ======= 8-< ======= cut here ============
      #!/bin/sh
      
      # Edit these as necessary:
      SVN=${HOME}/src/subversion/subversion/clients/cmdline/svn
      SVNADMIN=${HOME}/src/subversion/subversion/svnadmin/svnadmin
      
      # Clean up from a previous run.
      rm -rf wc repos
      
      # Set up the repository.
      ${SVNADMIN} create repos
      ${SVN} mkdir -m "Create a top-level directory." file://`pwd`/repos/trunk
      ${SVN} mkdir -m "Create a subdir." file://`pwd`/repos/trunk/subdir/
      
      # Create a working copy.
      ${SVN} co file://`pwd`/repos/trunk/ wc
      
      # Create a file in a subdir, just to make a change.
      cd wc/subdir
      echo "A file." > somefile
      ${SVN} add somefile
      ${SVN} ci -m "Add somefile."
      cd ..
      
      # Try to commit a property on the top-level dir.  It should fail
      # because out of date.
      ${SVN} propset "myprop" "myval" . 
      ${SVN} ci -m "Attempting to committing myprop on top dir."
      
      echo ""
      echo "That failure was expected.  Now we update and try again:"
      ${SVN} up
      ${SVN} ci -m "Attempting to committing myprop on top dir."
      
      echo ""
      echo "It succeeded this time, as expected."
      

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              kfogel Karl Fogel
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated: