Differences
This shows you the differences between the selected revisions of the page.
2013-08-14 | 2013-08-27 | ||
show full syntax for non-recursive mask (martin) | naming repative masks a partial masks + ordering sections by significance + articles (martin) | ||
Line 63: | Line 63: | ||
===== Path Mask ===== | ===== Path Mask ===== | ||
- | When the mask selects files and it makes sense to select them based on directory, you can extend the mask with a path mask. You should separate the path mask from the filename mask by a slash. For example mask ''/home/martinp/*.txt'' matches all text files within the directory. To match all text files within subtree, use mask ''/home/martinp/*.txt; /home/martinp/*/*.txt''((Simpler, but less precise, form would be ''/home/martinp*/*.txt'')). | + | When a mask selects files and it makes sense to select them based on directory, you can extend the mask with a path mask. You should separate the path mask from the filename mask by a slash. For example mask ''/home/martinp/*.txt'' matches all text files within the directory. To match all text files within subtree, use mask ''/home/martinp/*.txt; /home/martinp/*/*.txt''((Simpler, but less precise, form would be ''/home/martinp*/*.txt'')). |
- | For a relative path mask it makes no difference whether you use back (''\'') or forward slashes (''/''); the mask will always work for both local and remote paths. For example, the mask ''*/public_html/*.bak'' will match backup files both in ''D:\Documents\public_html\'' and ''/home/martinp/public_html/''. | + | The path mask is matched against full path, i.e. not against path relative path to a root of file transfer or synchronization. E.g. mask ''public_html/wiki/'' does not match ''/home/martinp/public_html/wiki'' directory, even if the root of file transfer or synchronization is ''/home/martinp''. Partial path mask that matches an absolute path may look like ''*/public_html/wiki/''. |
- | The path mask is matched against full path, i.e. not against path relative path to the root of file transfer or synchronization. E.g. mask ''public_html/wiki/'' does not match ''/home/martinp/public_html/wiki'' directory, even if the root of file transfer or synchronization is ''/home/martinp''. | + | For a partial path mask it makes no difference whether you use back (''\'') or forward slashes (''/''); the mask will always work for both local and remote paths. For example, a mask ''*/public_html/*.bak'' will match backup files both in ''D:\Documents\public_html\'' and ''/home/martinp/public_html/''. |
- | You can also specify full path to specific file or directory, both local and remote. For example if you want to match only specific ''.csv'' directory, not all, use ''/home/martinp/data/.csv/'' instead of ''.csv/''. | + | You can also specify full path to a specific file or directory, both local and remote. For example if you want to match only a specific ''.csv'' directory, not all, use ''/home/martinp/data/.csv/'' instead of ''.csv/''. |
===== Exceptions ===== | ===== Exceptions ===== | ||
For convenience, a masks ''*.*'' and ''*.'' are exceptions matching any file and any file without an extension, respectively, even if its name does not include any dot. | For convenience, a masks ''*.*'' and ''*.'' are exceptions matching any file and any file without an extension, respectively, even if its name does not include any dot. | ||