The docs about wildcards don't explain the difference between these wildcards very well in my opinion.
- {*}: this wildcard will match any text with blank spaces. Typically, it is used to match the text at the end of a card name or description.
- {* }: this wildcard will match a text until a blank space or the end of the text. Typically, it is used to match the text at the beginning/in the middle of a card name or description. When using this wildcard, make sure that you include a blank space in between the asterisk and the closing bracket.
- {?}: this wildcard will match the minimum amount of text.
What does "minimum amount of text" mean? For years my best guess was that the difference between {?} and {*} is that {?} doesn't match spaces, but I found that to not be true today. I have a Butler rule like this:
when a card with a name starting with "{?}-{?} {* }" is added to the board, set start date now and add link "https://blahblahblah.atlassian.net/browse/{wildcard1}-{wildcard2 }"
I would add a card with a title like "ABC-123 This is the Jira issue name" and it would add a link to https://blahblahblah.atlassian.net/browse/ABC-123, which is what I was aiming for. Today I created a card but forgot to add the ABC-123 before the Jira issue name, and the issue name happened to have a dash in it (let's say it was "Ticket name - testing 123"), so the link it added was something like https://blahblahblah.atlassian.net/browse/Ticket name-. So the first wildcard it found was "Ticket name", which has a space in it even though the wildcard is {?}, not {*}.
As a test, I created a card with the name "this is a - 232 test * 94823" which ended up adding a link to https://blahblahblah.atlassian.net/browse/this is a-
Then I changed the butler rule to look for a card with a name starting with "{*}-{*} {* }" and created a card with the same name, and the link that got added to that one was https://blahblahblah.atlassian.net/browse/this is a-232 test *
So yeah... can anyone explain how {?} actually works?
(preface that this is my own jank understanding through using Trello over the years)
My understanding is that, if there are multiple ways that a string would satisfy the pattern, {?} will always go for the version where it is shortest. Whereas {*} will go for the longest. Resolving from first to last.
Hence if the string is Mon-Tue-Wed
{*}-{*} will give "Mon-Tue" and "Wed"
{?}-{*} will give "Mon" and "Tue-Wed"
If there is only one way to satisfy the pattern, then they operate identically. so {*}-{*}-{*} and {?}-{?}-{?} would output the same, provided the string has 2 dashes.
----
I am less sure about {* }.. My understanding was that if there were multiple ways to resolve, it would always prefer to cut off at the first space. But after some testing, I find myself completely bamboozled, with certain strings matching {*}-{*} but not {* }-{*} depending on where I add spaces... so I threw up my hands ha
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.