https://rejetto.com/wiki/api.php?action=feedcontributions&user=195.229.242.57&feedformat=atomrejetto wiki - User contributions [en-gb]2024-03-28T18:17:18ZUser contributionsMediaWiki 1.38.4https://rejetto.com/wiki/index.php?title=HFS:_File_masks&diff=4212HFS: File masks2007-12-26T11:11:07Z<p>195.229.242.57: c4tbore</p>
<hr />
<div>racrozelr<br />
== What is it? ==<br />
<br />
A file mask denotes a set of files. It is usually something like this: <tt>*.jpg;*.gif</tt>. This example denotes any jpeg and gif files. <br />
Remember that the characters used in filenames are not case sensitive: so <tt>*.jpg</tt> and <tt>*.JPG</tt> refer to exactly the same set of files.<br />
<br />
== How does it work? ==<br />
<br />
The example above shows a ''double'' file mask. It has two atoms separated by the semicolon: ''*.jpg''<br />
and ''*.gif''. The semicolon is used to merge multiple masks: it is a ''special'' character.<br />
There are only three special characters in file masks: ''';''' '''*''' and '''?'''.<br />
<br />
== The star (*) ==<br />
<br />
The star (also called "asterisk") stands for ''any string'' of characters. If the mask contains only the star, it matches ANY file.<br />
<br />
If you put an A before the star <tt>A*</tt>, it matches any file starting with an A.<br />
<br />
If you put an A after the star <tt>*A</tt>, it matches any file ending with an A.<br />
<br />
<tt>A*B</tt> matches any file starting with an A and ending with a B.<br />
The example above shows ''*.jpg'' : it matches any file ending with .jpg (that is, jpeg images). jpeg files are relatively unusual because they sometimes end with ''.jpeg'' and more rarely with ''.jpe'' . (The part of a filename that comes after the period is called the file "extension", and is normally limited to three characters.) You could use the mask .jp* to match all types of jpeg files.<br />
<br />
The star also matches the ''null string'': <tt>A*.jpg</tt> matches files like ''A1.jpg'' , ''Adfgg.jpg''<br />
but also ''A.jpg''.<br />
<br />
== The question mark (?) ==<br />
<br />
This stands for a ''single character''. Something like <tt>A?B</tt> matches any filename that is three characters long and starts with an A and ends with a B. The length is fixed to three characters because ? can be replaced by<br />
only one character. Thus the ? does not match the null string as the * does.<br />
<br />
<br />
==Inverting the logic (\) ==<br />
<br />
So you want to hide filetypes, instead of showing specific filetypes?<br />
<br />
Insert a backslash <tt>\</tt> before <tt>*.ext</tt> to achieve opposite logic with the filter, and hide the filetypes you do not want visible to users. E.g <tt>\*.db;*.ini</tt></div>195.229.242.57