this post was submitted on 16 May 2025
280 points (97.9% liked)

Programmer Humor

23402 readers
1567 users here now

Welcome to Programmer Humor!

This is a place where you can post jokes, memes, humor, etc. related to programming!

For sharing awful code theres also Programming Horror.

Rules

founded 2 years ago
MODERATORS
top 17 comments
sorted by: hot top controversial new old
[–] baines@lemmy.cafe 35 points 5 days ago (2 children)

i have a recent diff where 300 changes are just things like moving whitespace

still fuck you for that mess

[–] wise_pancake@lemmy.ca 16 points 5 days ago (2 children)

I have vim setup to trim trailing white space, I get so pissed when a small change results in a 300 line diff because of poor code hygiene.

[–] hackeryarn@lemmy.world 21 points 5 days ago (3 children)

Do ya’ll just not use linters?

[–] baines@lemmy.cafe 11 points 5 days ago* (last edited 5 days ago)

in my case it is a massive legacy codebase that I don’t actually control

i get very sporadic deliveries of it and I’ve version controlled them into a jank progression

the original is in clearcase with now git on top of it and my version control is in svn

there are very shitty unresolvable reasons for all of this

but this last update was especially bad as one of their new coders is super fucking OCD and rejustifying headers and footers and fucking comments, so whitespace shit in files he is not editing code in otherwise, so that is like 300-500 files not lines

i want to break a knee cap

[–] exu@feditown.com 6 points 5 days ago

Linters won't necessarily help. You also need a code formatter that screams at you if you intent badly.

[–] prettybunnys@sh.itjust.works 1 points 5 days ago

Linters aren’t MVP my dude

[–] silico_biomancer@lemmy.nz 1 points 5 days ago (1 children)

https://github.com/axelf4/vim-strip-trailing-whitespace

There are plugins that will only trim modified lines, which resolves that issue

[–] wise_pancake@lemmy.ca 1 points 4 days ago

That’s a nice idea

Probably a bit more sophisticated than my regex solution.

[–] GreenKnight23@lemmy.world 6 points 5 days ago (3 children)

I had a new dev that was tasked with changing the colors of a button. took them 3 days to do it.

when I finally got the PR there were over 300 files changed and over 100k changes.

they "fixed" the while space. I asked them who asked them to do that. "Nobody, it's just maintenance on the codebase."

I then had an hour long call with them reviewing everywhere they "fixed" the whitespace and got through 10% of it. I asked them if they wanted to have another call tomorrow to review the rest or if they wanted to put the changes forward they were tasked with.

they got the hint and fixed their shit.

[–] lime@feddit.nu 2 points 4 days ago

please tell me you have an accepted code style with proper tooling and precommit hooks set up

[–] BitsAndBites@lemmy.world 4 points 5 days ago

Does the work item describe this technical cleanup? No? PR rejected for including out of scope work.

[–] baines@lemmy.cafe 2 points 5 days ago (1 children)

this, this is what I am dealing with, thank you for teaching him

[–] GreenKnight23@lemmy.world 5 points 5 days ago

I get it. they're just trying to show their usefulness and skills.

I did have a talk with them after work at the bar and told them not to worry about it. the best way to show your usefulness and dedication is to do the job you were assigned to do.

there are plenty of opportunities in your career that you can use to showcase your abilities without you needing to invent them on a whim. if anything doing that will do the opposite of what you're intending.

bright kid, just needed to be hit a couple times to see how the real world works.

[–] douglasg14b@lemmy.world 11 points 5 days ago

I mean, that could be extreme, or really not that bad.

Refactors have a way of generating a lot of changes. Half our job is code review, kind of have to get over it and go read some code.

If someone put the effort in to write it, it's your responsibility to put the effort in to read it and review it.

If the style is difficult to read and non-standard for your repository or not. Conventional then your repository and your engineering team should be following set standards to ensure consistency.

If you're doing this then most PRS shouldn't be that difficult to review.

I say this, spending a decent part of my week reviewing something like 40+ PRs.

[–] GreenKnight23@lemmy.world 6 points 5 days ago* (last edited 5 days ago)

rejected

"you're welcome"

[–] Alexstarfire@lemmy.world 7 points 6 days ago

Ehh, it really depends. Are most of those files import changes?

[–] KairuByte@lemmy.dbzer0.com 1 points 5 days ago

I feel attacked!