thank you for your reply, ~ actually works, but it’s scope may be a little bit too wide, because it also excludes all files in all directories with names that contain the ~ character. Ir might be necessary to use two expressions:
~* /~
The first to exclude files in the upper most directory, the second one for files in subdirectories.
When reading the documentation, I misread the instructions. I thought that expressions without a / are matched only against the file names without the path and that the / is necessary indicate that the path should be checked, too. It might be a good idea to complement the documentation; at least to mention that wildcards matches the / character, too.