[3.10] Auto-cancel old builds when new commit pushed to branch (GH-98009) (#98163)

* Auto-cancel old builds when new commit pushed to branch

* Add a fallback

Co-authored-by: Ezio Melotti <ezio.melotti@gmail.com>

* Use the same group for all workflows.

Co-authored-by: Ezio Melotti <ezio.melotti@gmail.com>
(cherry picked from commit 75751f4aa5d70f65856645a9128fd42d92d6692c)

Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>

Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
4 files changed