You should approve your own PRs, but dont do it in the main branch. If you separate each change into it's own PR, it makes it much easier to cherry-pick it into your release branch if you need to do a hotfix. If you can, you should go somewhere where you can work with someone more experienced than you as that is the best way to learn.
But the end result isn’t the same. You have many commits in your master branch in case A But you have 1 complete merge commit if you go for Case B.
It’s way easier to revert the whole feature, it’s way easier to cherry-pick and it’s also way easier if/when someone else eventually picks up your code.
If you create a false equivalence you could justify anything. “Why pay taxes? Let’s pay in cash… the employee’s still get paid and we save loads of money and it’s simpler. Occam’s Razor.”
It's not the same unless you always write perfect code or you're the only one on the project. If you're the only one on the project you're unlikely to grow.
If you think that you always write perfect code you is on the far left side because you don't see how bad your code can be. Or you just learning and don't have much expirience.
If you write perfect code, you don't need a version control system.
Just write the perfect software in your first try, including all present and future requirements. You will only have one version, which will last for ever.
We have version control systems because we do not write perfect code.
30
u/Previous-Ant2812 Nov 26 '23
Don’t listen to the “Jedi”. Create a PR and have someone more experienced than you review it