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

svndumpfilter exclude --targets wants pathname to start with '/'

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • trunk
    • 1.7.x
    • svndumpfilter

    Description

      I came across a bug with svndumpfilter. 
      
      When svndumpfilter exclude command accepts path prefixes starting with either /<pathname> 
      or just <pathname>, I expect it to work the same way when we use with --targets option.
      
      For Eg :
      
      Both of the following command works fine when we directly provide the 
      path prefix
      
      $ cat sample.dump | svndumpfilter exclude /tags > filtered4.dump
      
      $ cat sample.dump | svndumpfilter exclude tags > filtered4.dump
      
      However, when we use targets, it seems to be a must to prefix all the path prefixed with 
      a / which is not mentioned anywhere in the documentation as well.
      
      http://svnbook.red-bean.com/en/1.7/svn.ref.svndumpfilter.commands.c.exclude.html 
      
      http://svnbook.red-
      bean.com/en/1.7/svn.ref.svndumpfilter.html#svn.ref.svndumpfilter.sw.targets
      
      We had to lookup other sites to identify '/' was required in the 
      --targets filename being provided for the svndumpfilter to exclude those.
      
      The following is how I verified in my Apache SVN 1.7.4. Paul confirmed that it still 
      occurs with a trunk build @1384889
      
      ========
      WORKING:
      ========
      
      $ cat omit.txt
      /tags
      
      $ cat sample.dump | svndumpfilter exclude --targets /tmp/omit.txt > 
      filtered3.dump
      
      Excluding prefixes:
          '/tags'
      
      Revision 0 committed as 0.
      [...snip...]
      Revision 40 committed as 40.
      
      Dropped 1 node:
          '/tags'
      
      ==============
      NOT WORKING :
      ==============
      $ cat omit.txt
      tags
      
      $ cat sample.dump | svndumpfilter exclude --targets /tmp/omit.txt > 
      filtered2.dump
      
      Excluding prefixes:
          'tags'
      
      Revision 0 committed as 0.
      [...snip...]
      Revision 40 committed as 40.
      
      ------------------
      
      and the tags directory is not dropped. I wish this to be fixed to make it work in either 
      ways.
      

      Original issue reported by jeyanthan_cn

      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: