Calculate age for upcoming year

Cordi Powell
Contributor
December 3, 2024

I'm trying to create an automation that will add labels or notify me of clients who will turn 50 in 2025.  It would be great if the automation would create a list based on date of birth on January 1st of each year of individuals turning 50 without me having to annually up date the year.  Is this automation possible in Trello?

1 answer

0 votes
Dreamsuite Mike
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
December 4, 2024

Hi @Cordi Powell 

I wrote an article on this very topic:

https://community.atlassian.com/t5/Trello-articles/Mikes-Trello-Tips-Calculate-a-persons-age/ba-p/2505996 

 

I hope it helps but if you have any other questions, please follow up 

Cordi Powell
Contributor
December 4, 2024

Hi @Dreamsuite Mike ,

Thanks to the article, Trello is calculating the age and I have added labels based on specific ages.  

I'm curious, would you use regex or a wildcard to denote "any label" vs the "green" label to accomplish the following scheduled automation?

Every year on the 1st of January, copy each card with the "any label (not a specific label)" to today list on my week board.

Is there a regex cheat sheet or explanation guide that you can reference? 

Dreamsuite Mike
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
December 4, 2024

I would probably use a wildcard in the label unless you want to specify the conditions further. Like if it were certain types of label, I would probably use a regex to create OR conditions (see example 2 below)

I will pledge to make a Trello automation Regex guide before the end of this year.  For now, here are some useful bits of advice.

This is a great site for learning about it: 

https://www.rexegg.com/

And this is the go-to place to test out your regex search before putting it into a Trello automation command:

https://regex101.com/ 

Top Tip 1:Always get the regex expression right on Regex101.com before putting into a Trello command, there isn't much debug in Trello if it doesn't work

Top Tip 2:Google what you are looking for, easier than learning to construct yourself, almost every common example you can think of has a thread on stackoverflow. 

Top Tip 3: Use AI to generate the regex for you. Its not 100% correct but pretty close

 

Here are where you can use regex to match text in Trello automation:

  • Listnames
  • Cardnames
  • Descriptions
  • Comments
  • Label names
  • Custom field names and values
  • Checklist names
  • Checklist item names

 

Examples:

  1. Use regex to find anything (similar to wildcard) regex:/.*/i  (note, the /i at the end makes the search case insensitive)
  2. Use regex for OR scenarios.  Like When a card moves into list A OR list B.  regex:/List A|List B/. You can also use regex:/List(A|B)/
  3. Use regex to NOT. Like when a card moves into list NOT list A OR List C.  regex:/List(?!A|C)/
  4. Use regex to pull out parts of a string into wildcards.  Say you have a card name like Project Number: Project Name: Project Manager you could do this:
when a card name is changed to regex:/(.*):(.*):(.*)/i, set the custom field "Project Number" to "{wildcard1}" and set the custom field "Project Name" to "{wildcard2}" and set the custom field "Project Manager" to "{wildcard3}"

 

These are just a few, you can find more regex bits here on the community:

https://community.atlassian.com/t5/forums/searchpage/tab/message?advanced=false&allow_punctuation=false&filter=location&location=category%3Atrello&q=regex 

 

If you found this answered your question, please kindly click the Accept Answer button

 

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
PREMIUM
TAGS
AUG Leaders

Atlassian Community Events