5 ms·
Empty commits are useful to forcefully recreate a pipeline for example in GitLab
by pfoof 4y ago
Empty commits are useful to forcefully recreate a pipeline for example in GitLab
- nwellnhof 4y agoYou can also rerun a GitLab pipeline using the web UI. That's a lot cleaner than adding empty commits.
- Octabrain 4y ago100% agree but on certain situations, one doesn't have permissions for retriggering a build from the UI. (Sadly, I've been there)
- pfoof 4y agoYes and no. In case of changes to the runner environment and complex pipeline with many manual jobs, expiring artifacts, etc, it's easier to make an empty commit than to go around deleting what is obsolete and trying to find a working sequence
- _ikke_ 4y agoOr git commit --amend -C@ && git push -f
- RhysU 4y agoEmpty commits are useful to indicate that lengthy, manually run tests match some prior good state in development branches. For example commits like... 1.Good 2.Refactor 3.Rewrite 4.Empty with goodness re: 1 5.Rewrite 6.Refactor ...and now you retest and something is broken. You have an easy way to isolate any issues as happening after #4. And you have left markers for yourself 6 months from now if something goes wrong after a merge (i.e. confirm 1 and 4 match).