is it possible to write a regex where the last sign from match 1 is the start sign of match 2? I like to match all numbers between brackets and separated by a pipe. The situation is also complicated by the fact that, the match can only have one group deep.
This is my string: Text (1234|5678|901) Text (222) Text (333|444)
And I like to get:
- 1234
- 5678
- 901
- 222
- 333
- 444
But the regex schouldn't match:
Text (123 TextText |123) TextText |123 Text
I only found this regex [(|]{1}(\d+) with the problem, he also matched something like this Text (123 Text.
I have an example on regex101: https://regex101.com/r/taOU8o/1