Triggering pipeline for only major release

Hi, so I was looking to build a pipeline which will get triggered only for major releases and not for minor releases.

For Ex:
v1.0.0 → v1.2.0 #Should not trigger a pipeline
v1.23.45 → v2.0.0 #Should trigger a pipeline
v1.23.45 → v1.23.46 #Should not trigger a pipeline

What I have looked into, is using a global variable to determine if the job will be run or not but the global variable’s changed value does not remain persistent across jobs and also the pipeline will still be triggered.

It would be ideal if the pipeline is not triggered at all. So something in workflow rules need to do the trick I suppose but it doesnt support regex so that’s also kinda an issue.

Any help in this matter is appreciated, Thanks!