Shell 像这样使用时--exclude do在tar命令中做什么;tar cvfz../xxx--排除'/yyy/**'&引用;?
我看到这个命令:Shell 像这样使用时--exclude do在tar命令中做什么;tar cvfz../xxx--排除'/yyy/**'&引用;?,shell,unix,Shell,Unix,我看到这个命令: tar cvfz../xxx--排除'/yyy/**' xxx和yyy只是目录 现在,我不明白--exclude参数之后是什么 我认为这个图案是部分外壳 对于tar手册页: --exclude pattern Do not process files or directories that match the specified pattern. 因此,对于您的情况,它是排除yyy/目录中的所有文件和子目录,并进一步通过将排除模式指定为/yyy/**'***表示“
tar cvfz../xxx--排除'/yyy/**'
xxx和yyy只是目录
现在,我不明白--exclude参数之后是什么
我认为这个图案是部分外壳 对于tar手册页:
--exclude pattern
Do not process files or directories that match the specified pattern.
因此,对于您的情况,它是排除yyy/
目录中的所有文件和子目录,并进一步通过将排除模式指定为/yyy/**'
***
表示“*递归”(在子目录中,而不仅仅是在目录本身中),包括斜杠来存档
foo/**/bar
表示“foo”的任何子目录中的“bar”