News for hackers. Stuff that matters.
Re:Ask HN: Do you ever truly use your revision history? by saagarjha on Sunday March 08, 2020 @07:57AM (#22517592)
> For example, if I write exploratory code to test out a feature or throwaway code to do some analysis—anything I might want to use again, but don't want to commit to the codebase—I'll add it as a commit and then immediately revert the commit (i.e. make a new commit that deletes what I just added).

Why not use a named stash for something like this? It'll keep your history cleaner, and you can always find the stash by name later.

Re:Ask HN: Do you ever truly use your revision history? by dang on Sunday March 08, 2020 @01:59PM (#22519455)
Too complicated for me. I didn't even know that named stashes were a thing, and I wouldn't remember the names.

The nice thing about the approach is that there's only one place to look. I don't think it makes the history less clean, since it only contains things that were at some point, if only briefly, in the system.

Re:Ask HN: Do you ever truly use your revision history? by brazzy on Sunday March 08, 2020 @12:32PM (#22518913)
Can stashes be pushed to a remote repo?