Exclude patterns

From radmind

(Difference between revisions)
Jump to: navigation, search
Current revision (11:24, 7 April 2009) (edit) (undo)
(Paths with numbers)
 
(One intermediate revision not shown.)
Line 16: Line 16:
</pre>
</pre>
-
An alternative to using “/b” would be to substitute a wildcard characters. For a single space, either “?” or “[ ]” could be an option:
+
An alternative to using “/b” would be to substitute a wildcard characters. For a single space, “?” is an option:
<pre>
<pre>
Line 23: Line 23:
x /Library/Application?Support/VMware?Fusion/vmnet8/nat.mac
x /Library/Application?Support/VMware?Fusion/vmnet8/nat.mac
</pre>
</pre>
 +
 +
The “[ ]” character list might also work, but has not been verified:
<pre>
<pre>
Line 29: Line 31:
x /Library/Application[ ]Support/VMware[ ]Fusion/vmnet8/nat.mac
x /Library/Application[ ]Support/VMware[ ]Fusion/vmnet8/nat.mac
</pre>
</pre>
-
 
==Paths with numbers==
==Paths with numbers==
-
Some paths you intend to exclude may involve numbers. This is especially true for version numbers. Place a number range between angle brackets to construct a pattern, in the same manner as described for the config file syntax in the radmind man page.
+
Some paths you intend to exclude may involve numbers. This is especially true for version numbers, which can vary over a range of software releases. Place a number range between angle brackets to construct a pattern, in the same manner as described for the config file syntax in the radmind man page.
For example, to exclude Python compiled and object files:
For example, to exclude Python compiled and object files:

Current revision

[edit] Paths with spaces

Exclude a path that contains a space by substituting “\b” for each space. For example, to exclude the path “/Library/Application Support/VMware Fusion/vmnet8/nat.mac” from VMware Fusion installations on Mac OS X, use:

# Excludes the path /Library/Application Support/VMware Fusion/vmnet8/nat.mac
x /Library/Application\bSupport/VMware\bFusion/vmnet8/nat.mac

This results in the following response from the twhich utility:

$ sudo twhich "/Library/Application Support/VMware Fusion/vmnet8/nat.mac"
# Exclude
# exclude pattern: /Library/Application Support/VMware Fusion/vmnet8/nat.mac

An alternative to using “/b” would be to substitute a wildcard characters. For a single space, “?” is an option:

# Excludes the path /Library/Application Support/VMware Fusion/vmnet8/nat.mac
# Uses the ? wildcard
x /Library/Application?Support/VMware?Fusion/vmnet8/nat.mac

The “[ ]” character list might also work, but has not been verified:

# Excludes the path /Library/Application Support/VMware Fusion/vmnet8/nat.mac
# Uses the [ ] character list
x /Library/Application[ ]Support/VMware[ ]Fusion/vmnet8/nat.mac

[edit] Paths with numbers

Some paths you intend to exclude may involve numbers. This is especially true for version numbers, which can vary over a range of software releases. Place a number range between angle brackets to construct a pattern, in the same manner as described for the config file syntax in the radmind man page.

For example, to exclude Python compiled and object files:

# Python compiled and object module files for Python 2.x and 3.x
x /Library/Python/<2-3>.<0-9>/site-packages/*.py[oc]

The <2-3>.<0-9> pattern would match both version 2.x and 3.x of Python. The ending *.py[oc] pattern would match files ending in either “.pyc” or “.pyo” in the “site-packages” directory.

Personal tools