Since it took me a looong while to figure out the existing simple solution, I thought I might as well share it.
In a script, if you want to filter items (e.g. on their reported attributes), it may not work when processing files or folders containing "[" or "#" or ";".
- A solution involves using the flag: "filter item, 1", but it only takes care of the "["
- Another solution is to escape those characters with square brackets, i.e. "[[]", which may become troublesome with exact matches...
- fully "quote" every item (e.g. in your foreach or your regexmatches),
- and separate them with a "|",
- without escaping any character, and
- without using the ", 1" flag.
Note that your item(s)/variable(s) must really be quoted, so for it to work, the resolved command should look like e.g.
filter "a#c.txt"|"a;c.txt";
filter """a#c.txt""";
Hoping this may help someone filtering by custom labels or specific properties...
Flux
XYplorer Beta Club