this post was submitted on 20 Nov 2024
864 points (97.6% liked)

Programmer Humor

19623 readers
2830 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 1 year ago
MODERATORS
864
submitted 2 days ago* (last edited 2 days ago) by [email protected] to c/[email protected]
you are viewing a single comment's thread
view the rest of the comments
[–] [email protected] 33 points 2 days ago (10 children)

I understand the impulse to be empathetic and kind. But it's very hard to respond in good faith to someone who just made a post where more than half the words are "fuck you".

[–] madcaesar 28 points 2 days ago (9 children)

A feature that permanently deletes 5000 files with one click without warning deserves a fuck you.

[–] [email protected] 21 points 2 days ago (8 children)

It had a reasonably clear warning, though; a screenshot is included in this response from the devs. But note that the response also links to another issue where some bikeshedding on the warning occurred and the warning was ultimately improved.

[–] Buddahriffic 13 points 2 days ago (3 children)

I disagree that that warning is reasonably clear. Even the comment that included it has the line of thought, where the user, not knowing what terms git uses thinks that they just did an action that is going to change each of their files. It makes sense that they'd want to discard those changes. That user then goes on with some snark about not wanting to learn any more about what they are playing with and that other programs would do the same, but "discard changes" seems like it would have a clear meaning to someone who doesn't know git.

The warning says it isn't undoable but also doesn't clarify that the files themselves are the changes. Should probably have a special case for if someone hits discard changes on a brand new repository with no files ever checked in and hits discard on a large number of files instead of checking them in. Even a "(This deletes all of the local files!)" would make it clear enough to say what the warning is really about.

[–] [email protected] 2 points 1 day ago (1 children)

Well, yeah, that's why the linked ticket led to a massive improvement:

[–] Buddahriffic 1 points 1 day ago

That's way better. His sacrifice benefited others in the end.

[–] [email protected] 7 points 2 days ago

Even if you know git, you wouldn't assume that "discard all changes" affects untracked files. It's bad design all around

[–] [email protected] 3 points 2 days ago

My git gui has a tick box on that prompt to specifically include added files. I now see why haha

load more comments (4 replies)
load more comments (4 replies)
load more comments (4 replies)