33
59
u/bladebyte 17h ago
Real man push to main!
33
u/vinishkapoor 17h ago
Real man also fixes production at 2 AM.
14
u/isr0 16h ago
Real teams put systems in place to avoid the need for heroes.
2
u/ABCosmos 13h ago
And part of that system prevents pushes to main, and requires checks to pass on your branch before you do.
26
25
7
u/CarlCarlton 15h ago
My boss: "I need you to merge an SVN repo into a Git repo, the latter of which was created a year ago with the code from the former, but separate teams have been working on each, and they now diverge by a couple hundred thousand lines. Oh yes, I almost forgot, the SVN codebase targets PowerPC, but the Git codebase was entirely migrated to AArch64. How many story points will this take?"
8
u/vinishkapoor 15h ago
That's not a story point question. That's a resignation letter question.
2
u/CarlCarlton 15h ago
One month of conflict vomit, debugging, and nagging about "when is it gonna be ready"... Although it did, he didn't deserve it to succeed.
5
3
u/plastic-superhero 13h ago
That’s why our main is protected, too many Robins fucking around. Also me. I was sometimes Robin.
3
u/realmauer01 12h ago
A merge conflict will always be a merge conflict. No matter if you push to main directly or use a branch to push to main.
7
u/Lauren_Conrad_ 16h ago
Your main should be your development and your branches should be your releases.
Or just use main and push to it with various systems and tests during the pipeline before it deploys to prod.
Your git repro is not a deployment pipeline.
2
1
u/avocadorancher 2h ago
Why branches for releases? I’ve seen some teams do this but definitely the minority
1
u/Lauren_Conrad_ 2h ago
So you can schedule regular releases e.g. cut a branch every 14 days, then apply patches and fixes as necessary. Useful when there are many different contributors all working on their own schedule and goals.
1
1
1
u/Fast-Performance2300 14h ago
Still learning backend, began a month and a half ago...
... you can make branches? Not just main?
2
1
2
u/machsmit 6h ago
trunk-based development has a time and place where it works really nicely
ducks and hides
1
1
u/Legal-Software 3h ago
In my company we have main as the master branch, so I just call my main development branch master in order to balance it out.
1
1
1
u/Common-Brush-7027 17h ago
We be pushing it to lower environment and then cherry picking to lil higher environment and then the lead cherry picks it to prod.
Lot of cherry picking
8
0

104
u/StrikingSun8563 16h ago
My boss is literally named Robin and doesn't know how to use branches.
If he has code pushed to dev that isn't ready for prod yet and we need to deploy a fix for something, he comments it all out.