Unknown | 114 lines | 114 code | 0 blank | 0 comment | 0 complexity | 9fe0ead2a7ee8fd28be820d854ca8037 MD5 | raw file
1.TH DESCEND 1 "31 March 1992" 2.SH NAME 3descend \- walk directory tree and execute a command at each node 4.SH SYNOPSIS 5.B descend 6[ 7.B \-afqrv 8] 9.I command 10[ 11.I directory 12\&.\|.\|. 13] 14.SH DESCRIPTION 15.B descend 16walks down a directory tree and executes a command at each node. It 17is not as versatile as 18.BR find (1), 19but it has a simpler syntax. If no 20.I directory 21is specified, 22.B descend 23starts at the current one. 24.LP 25Unlike 26.BR find , 27.B descend 28can be told to skip the special directories associated with RCS, 29CVS, and SCCS. This makes 30.B descend 31especially handy for use with these packages. It can be used with 32other commands too, of course. 33.LP 34.B descend 35is a poor man's way to make any command recursive. Note: 36.B descend 37does not follow symbolic links to directories unless they are 38specified on the command line. 39.SH OPTIONS 40.TP 15 41.B \-a 42.I All. 43Descend into directories that begin with '.'. 44.TP 45.B \-f 46.I Force. 47Ignore errors during descent. Normally, 48.B descend 49quits when an error occurs. 50.TP 51.B \-q 52.I Quiet. 53Suppress the message `In directory 54.IR directory ' 55that is normally printed during the descent. 56.TP 57.B \-r 58.I Restricted. 59Don't descend into the special directories 60.SB RCS, 61.SB CVS, 62.SB CVS.adm, 63and 64.SB SCCS. 65.TP 66.B \-v 67.I Verbose. 68Print 69.I command 70before executing it. 71.SH EXAMPLES 72.TP 15 73.B "descend ls" 74Cheap substitute for `ls -R'. 75.TP 15 76.B "descend -f 'rm *' tree" 77Strip `tree' of its leaves. This command descends the `tree' 78directory, removing all regular files. Since 79.BR rm (1) 80does not remove directories, this command leaves the directory 81structure of `tree' intact, but denuded. The 82.B \-f 83option is required to keep 84.B descend 85from quitting. You could use `rm \-f' instead. 86.TP 87.B "descend -r 'co RCS/*'" /project/src/ 88Check out every RCS file under the directory 89.BR "/project/src" . 90.TP 91.B "descend -r 'cvs diff'" 92Perform CVS `diff' operation on every directory below (and including) 93the current one. 94.SH DIAGNOSTICS 95Returns 1 if errors occur (and the 96.B \-f 97option is not used). Otherwise returns 0. 98.SH SEE ALSO 99.BR find (1), 100.BR rcsintro (1), 101.BR cvs (1), 102.BR sccs (1) 103.SH AUTHOR 104Lowell Skoog 105.br 106Software Technology Group 107.br 108John Fluke Mfg. Co., Inc. 109.SH BUGS 110Shell metacharacters in 111.I command 112may have bizarre effects. In particular, compound commands 113(containing ';', '[', and ']' characters) will not work. It is best 114to enclose complicated commands in single quotes \(aa\ \(aa.