News for hackers. Stuff that matters.
Re:Why is it so hard to see code from 5 minutes ago? by bottled_poe on Friday February 19, 2021 @12:26AM (#26190080)
It’s amazing how many developers don’t have a working knowledge of fundamental tools - like version control and debuggers. I honestly don’t know how you could get hired without this basic knowledge.
Re:Why is it so hard to see code from 5 minutes ago? by wingerlang on Friday February 19, 2021 @01:15AM (#26190292)
Undo/redo have nothing to do with this though. Undo/redo is for looking at changes you did while in the middle of writing something. Before committing.

This is from an example I did just yesterday.

Let’s say you’re moving a piece of code by cut n paste. You cut it but in the middle of changing you copied something else, maybe accidentally. Undo and cut it again. Redo and it’s now back in your clipboard.

You could copy from the diff but you’d get extra tokens to clean up.