git fetch should use --prune
Summary
During development, users may be deleting, force pushing etc to branches and tags. However when using the git fetch strategy, branches are not pruned. This may cause the following kind of errors to appear:
job:
script:
- git checkout -b release/${GIT_COMMIT_TAG}
produces
$ git checkout -b "release/${CI_COMMIT_TAG:?}"
fatal: A branch named 'release/v0.1' already exists.`
Granted, this could be resolved by having git fetch --prune in the pipeline, but that's a hacky work-around at best. The branch should not have exist anymore, as it was removed from the repo ages ago.