4

I'm trying to link issues in commit messages from Bitbucket to Youtrack, but can't find proper solution.

I have for ex. commit message "CORE-214 adding foreign currency" and want to make CORE-214 link to our Youtrack as described here - https://blog.bitbucket.org/2012/06/18/use-custom-regex-to-link-anywhere-on-bitbucket/

So I create new custom link in Repository / Settings / Links using Add a custom link:

Replacement URL: https://ouryoutrack.myjetbrains.com/youtrack/issue/\1
Raw regex: CORE-\d+

However no links are showing in commit messages. We were using JIRA links integration before and everything was working fine, but that was configured using Add a repository link to JIRA feature.

Ondřej Šotek
  • 1,793
  • 1
  • 15
  • 24

1 Answers1

4

The \1 part of the replacement regex is meant to insert a captured group from the regular expression. Your regex doesn't include any capture groups.

Try this instead: (CORE-\d+).

ChrisGPT was on strike
  • 127,765
  • 105
  • 273
  • 257