Details
-
Suggestion
-
Resolution: Duplicate
-
None
-
Linux, Oracle DB
Description
The attachments macro has a patterns field which is supposed to allow matching via regular expressions. Unfortunately, the way confluence handles characters keeps this from being useful.
It can be used to do something simple like "list only documents ending with doc".
Example: patterns=.*doc (works correctly)
but anything more useful like "list all documents except word and excel documents" cannot be done:
Example: patterns!=.*\.(doc)|(xls) (completely fails)
The reasons this fails are listed:
A) We cannot use !=
B) We cannot use \ (backslash) anywhere in the regular expression (which makes it hard to do anything halfway complex)
C) We cannot use | (pipe) anywhere because confluence uses it as the seperator for fields for macros
The basic functions that someone might use this for (listing all files except those of a certain type or types) do not function because the regular expression handling does not work correctly.
Attachments
Issue Links
- duplicates
-
CONFSERVER-4009 Allow escaping of special characters (e.g. pipe '|', backslash '\' and braces '}') in macro parameters for regular expressions, links, etc.
- Closed