如果用户指定一个目录作为参数,几乎所有的CVS命令都会在该目录中递归地执行。例如,假设有如下目录结构:
$HOME
|
+--tc
| |
+--CVS
| (internal cvs files)
+--Makefile
+--backend.c
+--driver.c
+--frontend.cd
+--parser.c
+--man
| |
| +--CVS
| | (internal cvs files)
| +--tc.1
|
+--testing
|
+--CVS
| (internal cvs files)
+--testpgm.t
+--test2.t |
如果tc是当前工作目录,则以下操作为真:
cvs update testing等价于:
cvs update testing/testpgm.t testing/test2.t |
cvs update testing man会更新子目录下的所有文件。
使用cvs update . 或者只使用cvs update会更新tc目录中的所有文件。
如果不给update命令赋参数,它会更新当前工作目录中的所有文件和所有子目录。换句话说,“.”是update命令的默认参数。这点对其它CVS命令也适用,不仅仅是update命令。
使用选项-l可以关闭CVS命令的递归执行方式。相反地,如果在~/.cvsrc中指定-l选项关闭了递归执行方式,可以使用-R选项来重新开启[默认选项与 ~/.cvsrc 文件 在 附录 A]。
$ cvs update -l # Don't update files in subdirectories |