Hello everyone,
I'd like to craft/get a name of the suggested branch name via a smart templates.
For instance, if the ID of the ticket is PRJ-1 and the title is Backend API Created the branch name suggested by JIRA would be suggested as `PRJ-1-backend-api-created`.
Is there a way I can get it? Maybe there is a way to sanitize the title in excatly the same way via smart templates?
Thanks.
UPDATE 1:
I guess the key would be to use `replaceAll()` but I'm yet to find the regex that would be 1:1 with what branch name generator uses.
UPDATE 2:
I ended up with the following regex-based snippet: `.trim().toLowerCase().replaceAll("[^A-Za-z0-9]"," ").replaceAll(" {2,}"," ").trim().replaceAll(" ","-")