代码拉取完成,页面将自动刷新
同步操作将从 src-openEuler/tar 强制同步,此操作会覆盖自 Fork 仓库以来所做的任何修改,且无法恢复!!!
确定后同步将在后台操作,完成时将刷新页面,请耐心等待。
From 18112ded916cf62b3bd3c0ffb9530e4ade3d2209 Mon Sep 17 00:00:00 2001
From: rpm-build <rpm-build>
Date: Mon, 28 Jul 2014 08:16:33 +0200
Subject: [PATCH 7/9] Document exclude mistakes with
.. usually with --no-wildcards-match-slash & --anchored options.
Upstream bugreport (still downstream):
http://www.mail-archive.com/bug-tar@gnu.org/msg04488.html
Related: #903666
---
doc/tar.texi | 67 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 67 insertions(+)
diff --git a/doc/tar.texi b/doc/tar.texi
index a000f3f..2695d22 100644
--- a/doc/tar.texi
+++ b/doc/tar.texi
@@ -8051,6 +8051,73 @@ The following table summarizes pattern-matching default values:
@item Exclusion @tab @option{--wildcards --no-anchored --wildcards-match-slash}
@end multitable
+@subsubsection Wildcard matching confusion
+Using of @option{--[no-]anchored} and @option{--[no-]wildcards-match-slash}
+was proven to make confusion. The reasons for this are probably different
+default setting for inclusion and exclusion patterns (in general: you shouldn't
+rely on defaults if possible) and maybe also because when using any of these two
+options, the position on command line matters (these options should be placed
+prior to the member name on command line).
+
+@noindent
+Consider following directory structure:
+
+@smallexample
+$ find path/ | sort
+path/
+path/file1
+path/file2
+path/subpath
+path/subpath/file1
+path/subpath/file2
+path/subpath2
+path/subpath2/file1
+path/subpath2/file2
+@end smallexample
+
+@noindent
+To archive full directory @samp{path} except all files named @samp{file1} may be
+reached by any of the two following commands:
+
+@smallexample
+$ tar -cf a.tar --no-wildcards-match-slash --no-anchored path \
+ --exclude='*/file1'
+$ tar -cf a.tar --wildcards-match-slash path --exclude='*/file1'
+@end smallexample
+
+@noindent
+Note that the @option{--wildcards-match-slash} and @option{--no-anchored} may be
+omitted as it is default for @option{--exclude}. Anyway, we usually want just
+concrete file (or rather subset of files with the same name). Assume we want
+exclude only files named @samp{file1} from the first subdirectory level.
+Following command obviously does not work (it still excludes all files having
+@samp{file1} name):
+
+@smallexample
+$ tar -cf a.tar --no-wildcards-match-slash path \
+ --exclude='*/file1' | sort
+@end smallexample
+
+@noindent
+This is because the @option{--no-anchored} is set by default for exclusion.
+What you need to fix is to put @option{--anchored} before pathname:
+
+@smallexample
+$ tar -cvf a.tar --no-wildcards-match-slash --anchored path \
+ --exclude='*/file1' | sort
+path/
+path/file2
+path/subpath1/
+path/subpath1/file1
+path/subpath1/file2
+path/subpath2/
+path/subpath2/file1
+path/subpath2/file2
+@end smallexample
+
+@noindent
+Similarly you can exclude second level by specifying @samp{*/*/file1}.
+
@node quoting styles
@section Quoting Member Names
--
1.9.3
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。