https://confluence.atlassian.com/display/BitbucketServerKB/Integrating+with+custom+JIRA+issue+key gives a regex to use in BBS (Stash) for issues keys such as ABC-123
((?<!([A-Z]{1,10})-?)[A-Z]+-\d+)
But is lookbehind really needed in the pattern?
The lookbehind is used to ensure that a string like ABC-DEF-123
is not matched as DEF-123
. Note that this type of pattern is used in Crucible review IDs and sometimes in Bamboo build keys.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.