JPDev@programming.dev to Programmer Humor@programming.dev · 8 months agoReview Pleaseprogramming.devimagemessage-square60fedilinkarrow-up1804arrow-down116
arrow-up1788arrow-down1imageReview Pleaseprogramming.devJPDev@programming.dev to Programmer Humor@programming.dev · 8 months agomessage-square60fedilink
minus-squaresunbytes@lemmy.worldlinkfedilinkarrow-up86·8 months agosets the diff to ignore whitespace Lines changed: 3
minus-squarekamen@lemmy.worldlinkfedilinkarrow-up27arrow-down1·7 months agoThe pipeline should handle formatting. No matter how you screw it up, once you commit, it gets formatted to an agreed upon standard.
minus-squaresunbytes@lemmy.worldlinkfedilinkarrow-up2·7 months agoSome diff tools don’t handle indentation by default. So if you add a wrapper, it counts everything inside it as “changed”
minus-squarekamen@lemmy.worldlinkfedilinkarrow-up2·7 months agoThat’s what “toggle whitespace diff” is for.
minus-squarekamen@lemmy.worldlinkfedilinkEnglisharrow-up2·7 months agoPre-commit hooks is a common approach to this, so that whatever is committed gets processed. Another possibility would be to set a bot on the repo to do automated commits after human-made ones, but that can get a little noisy.
sets the diff to ignore whitespace
Lines changed: 3
The pipeline should handle formatting. No matter how you screw it up, once you commit, it gets formatted to an agreed upon standard.
Some diff tools don’t handle indentation by default.
So if you add a wrapper, it counts everything inside it as “changed”
That’s what “toggle whitespace diff” is for.
You can do that? How?
Pre-commit hooks is a common approach to this, so that whatever is committed gets processed. Another possibility would be to set a bot on the repo to do automated commits after human-made ones, but that can get a little noisy.