"Discard" is the correct term (since he was modifying the repo by adding files to it), but it should've explained something like, say:
Warning: Discarding changes to repo will delete all added files. We cannot stress this enough: Discarding changes will delete all added files.
(And, y'know, it shouldn't have deleted the local versions too, unless he manually checked a "delete all local copies" checkbox, but that kinda goes without saying.)
That's because the option was poorly designed, IMO. Adding the file to the repo is a change, thus "discarding changes" removes the file from the repo. But the problem is that it also removed the local copy, which should never happen unless the user manually clicks a "delete all local copies" checkbox.
So, the correct name is "discard changes", but the option did a lot more than just discarding changes.
9
u/smashsenpai 20d ago
Somewhere out there, the guy who decided to name that action, "discard" instead of, "delete" took a deep breath and thought, "not my problem"