News for hackers. Stuff that matters.
Re:This is how I git by brmgb on Tuesday November 10, 2020 @05:10AM (#25044314)
I don't understand your comment about tools. Checkout is a git command (with an admittedly terrible ux). It is not part of git data model.

Like the article writer, I never myself use stash. I personally don't understand why they were added to the git ux. I think they needlessly make git more complex. Under the hood, a stash is just a commit anyway. You might retort that this is an implementation detail but as usual with Git, this leaks into the way it is used: if you ever lose a stash by mistake, you will have to go fish the corresponding commit in the reflog.

Re:This is how I git by hibbelig on Tuesday November 10, 2020 @10:09AM (#25046775)
I use stashes via the autostash feature. For unspeakable reasons, I have to have locally modified files in my repo to run the software and the tests. (Of course, it shouldn't be like this.)

So I can `git pull --rebase --autostash` and this works even with local modifications.

Re:This is how I git by karmakaze on Tuesday November 10, 2020 @03:07PM (#25051124)
TIL, thanks! I've been stash; rebase; pop'ing
Re:This is how I git by zwp on Tuesday November 10, 2020 @05:50AM (#25044551)
I have a vague recollection of feature parity with Mercurial's shelves but I don't remember which came first. They look very similar: https://www.mercurial-scm.org/wiki/ShelveExtension

Perhaps a Mercurial user can say if shelves are more useful? (And if so, why?).

Re:This is how I git by steerablesafe on Tuesday November 10, 2020 @06:00AM (#25044601)
I'm a Mercurial user and I use bookmarks instead, aka git-like branches.