Use variables to control which branches are the main ones
Now that everyone ships a GitLab version modern enough to have https://gitlab.com/gitlab-org/gitlab/-/issues/35438 fixed we can drop the YAML anchor workarounds and purely rely on variables to control the rules conditions matching on branch names.
This frees downstreams from having to patch the pipeline, as they can now just override the variables in the CI settings.