News for hackers. Stuff that matters.
Re:Git is too hard by wpietri on Tuesday November 17, 2020 @09:40AM (#25124200)
I think more than one thing can be a problem. The CLI is confusing and the model is complicated. This means people can get themselves into weird, hard-to-debug situations. Or end up copy-pasting incantations in hopes of fixing problems, but instead might lose their work.
Re:Git is too hard by RichardCA on Tuesday November 17, 2020 @03:22PM (#25129261)
I've never seen a scenario that resulted in a developer losing work. You can always retrieve things out of the commit history, even in pathological situations.
Re:Git is too hard by wpietri on Thursday November 19, 2020 @05:43PM (#25155242)
I have lost work. A colleague force-pushed something because he thought he understood Git well enough to get away with it.
Re:Git is too hard by RichardCA on Saturday November 21, 2020 @03:21AM (#25168477)
If you can find your prior branch head with git reflog, you can assign a new branch name to it and push it.

Then go back to your force-pushing colleague and tell him to resolve the merge conflict he created by thinking he was too clever.

Re:Git is too hard by RichardCA on Saturday November 21, 2020 @03:56AM (#25168581)
The command "git log --all --oneline --graph --reflog" will give you an exhaustive listing of the commit graph in your local repo.

Examine the output of that command in detail before declaring your work to be lost.