| ▲ | mmlb 2 hours ago |
| I've had that same "what's the point" thought every time I've read about stacked PRs, but recently had an (obvious) epiphany. The benefit is you get CI for each commit! I've always hated fixup/typo/fix tests commits and toyed with having a CI check that enforced ci passing on each commit but this drops that need. |
|
| ▲ | satvikpendem 2 hours ago | parent | next [-] |
| I don't get it, we already have CI for each commit, at least at our workplace, enforced. |
|
| ▲ | skydhash 2 hours ago | parent | prev [-] |
| > I've always hated fixup/typo/fix tests commits and toyed with having a CI check that enforced ci passing on each commit but this drops that need. Can't you run your CI locally? I know it's not feasible for some codebase, but at least the linting, formatting, unit tests, some integration tests should be able to be done locally. |
| |
| ▲ | steveklabnik 2 hours ago | parent [-] | | You can't have mac/windows/linux/whatever all locally simultanously. Not every project requires this, but for those that do, it's impossible. Also, it is much harder to enforce "everyone must run each commit through the CI equivalent properly" than it is when it's on your forge. | | |
| ▲ | skydhash 2 hours ago | parent [-] | | > You can't have mac/windows/linux/whatever all locally simultanously. Why can't you? That's what VMs are for. And even then, most cross-platform codebases have an abstraction layer that rarely changes. So even testing on one platform can raise your confidence very high. > Also, it is much harder to enforce "everyone must run each commit through the CI equivalent properly" Again why? I wouldn't care about the dev's local branch. But what is send to the main repo can be easily scripted to run the CI on every commit. You just send the result back with each commit that fails. They can replicate the same workflow on their local workspace as a pre-push process. |
|
|