git push --force and how to deal with it
16-Aug-2024 699
Now, if you’re thinking, “this doesn’t sound like something I’d ever do”, well, let’s not get overly confident. Sooner or later, this is going to happen. When working with several remotes in the same Git repository, eventually, you will git push --force into main (or another important branch that should’ve never been messed with).This might happen, for instance, when deploying with Heroku, which uses separate Git remotes to build and deploy an application. Following a long day of work, it could be incredibly easy to execute git push --force instead of the usual git push --force heroku main.
git push --force and how to deal with it #ruby #rubydeveloper #rubyonrails #--force https://rubyonrails.ba/link/git-push-force-and-how-to-deal-with-it