Menu

#78 A fuller explanation of '--depth ARG' in section 'svn Options' would be useful

en-1.6
Fixed
nobody
None
Medium
Enhancement
2011-08-29
2010-04-19
Anonymous
No

Originally created by: chris...@gmail.com
Originally owned by: cmpilato

Currently it reads:
    --depth ARG
    Instructs Subversion to limit the scope of an operation to a particular tree depth.
    ARG is one of empty, files, immedi-ates, or infinity.

The source code file svn_types.h has this more useful info:

  /* Just the named directory D, no entries.  Updates will not pull in
     any files or subdirectories not already present. */
  svn_depth_empty      =  0,

  /* D + its file children, but not subdirs.  Updates will pull in any
     files not already present, but not subdirectories. */
  svn_depth_files      =  1,

  /* D + immediate children (D and its entries).  Updates will pull in
     any files or subdirectories not already present; those
     subdirectories' this_dir entries will have depth-empty. */
  svn_depth_immediates =  2,

  /* D + all descendants (full recursion from D).  Updates will pull
     in any files or subdirectories not already present; those
     subdirectories' this_dir entries will have depth-infinity.
     Equivalent to the pre-1.5 default update behavior. */
  svn_depth_infinity   =  3

Further it appears that the 'obsolete' --recursive/--non-recursive options map to different values
dependant on the sub-command. E.g. update => infinity or files, status => infinity or immediates.
The description of each sub-command should state explicitly what mapping it uses.
[The output from `svn help <cmd>` is also ambiguous with regard to this.]

[I would be willing to make an exhaustive list of the mappings if it's going to be
used to update the book, but I won't if I'd just be wasting my time.]

Discussion

  • Anonymous

    Anonymous - 2011-02-21

    Originally posted by: chris...@gmail.com

    Additional:
        svn: --depth and --set-depth are mutually exclusive.
    This appears nowhere in the book.

    The `--set-depth ARG` option also supports the 'exclude' argument.
    This is also not mentioned in the book.

    From svn_types.h:
      /* Exclude (i.e., don't descend into) directory D. */
      svn_depth_exclude    = -1,

     
  • Anonymous

    Anonymous - 2011-06-28

    Originally posted by: cmpilato

    (No comment was entered for this change.)

    Owner: cmpilato

     
  • Anonymous

    Anonymous - 2011-07-06

    Originally posted by: cmpilato

    (No comment was entered for this change.)

    Labels: Milestone-en-1.6

     
  • Anonymous

    Anonymous - 2011-07-15

    Originally posted by: cmpilato

    Pushing this off as not-strictly-needed-for-1.6-coverage.  (Trying to get to the 1.7 work sooner rather than later.)

    Labels: Milestone-en-1.7

     
  • Anonymous

    Anonymous - 2011-08-29

    Originally posted by: cmpilato

    Finished in [r4043]; backported to the 1.6 version in [r4044].

    Labels: -Milestone-en-1.7 Milestone-en-1.6
    Status: Fixed

     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.