←back to thread

Jujutsu for everyone

(jj-for-everyone.github.io)
434 points Bogdanp | 3 comments | | HN request time: 0.001s | source
Show context
idoubtit ◴[] No.45085587[source]
I've now seen a dozen of articles that explain that jj is wonderful and better than Git for everything. This tutorial is of the same kind. Now that I've read extensively about the good part, I'd be more interested by the bad and the ugly. Because my experience with jj was more balanced.

When I tried jj, I found a few pain points that made me return to Git. For instance, I was sharing a branch with a co-worker where we were just piling commits as soon as they were ready (after `pull --rebase` if necessary). Since jj doesn't have names branches, that workflow was easy with git and tedious with jj – even with the `tug` alias. The process in the "Tracking remote bookmarks" chapter of this tutorial still doesn't look nice to me.

Another pain point was that jj could not colocate with light clones, like `git clone --filter=blob:none`. Maybe that's fixed now.

replies(7): >>45085702 #>>45085823 #>>45085842 #>>45085897 #>>45086038 #>>45089721 #>>45095158 #
shepherdjerred ◴[] No.45085842[source]
One thing that has bitten me a few times is jj randomly losing my changes. As in, I'll be working in Cursor, not run any mutating jj command (maybe I'll run jj status or jj log, but nothing else), and later on my changes are gone from my repository (often times with a message about a stale workspace).

I'm not sure if this is somehow related to my IDE, working in a huge monorepo, or something else, but it has been quite painful.

Aside from that, though, I do really like the flexibility jj provides.

replies(3): >>45086378 #>>45087511 #>>45087664 #
1. gcr ◴[] No.45087664[source]
Your changes are almost certainly in the op log, even as just bare snapshot operations. Have you been able to search that and recover them?

(i've found jj undo quite robust, i'd be surprised if you ever actually lost work tbh)

replies(1): >>45088113 #
2. shepherdjerred ◴[] No.45088113[source]
If this happened with Git I feel confident enough to recover my work. I'm not familiar enough with jj, so usually when this happens I've used VS Code's timeline feature to recover my work.
replies(1): >>45089847 #
3. raylu ◴[] No.45089847[source]
`jj op` has `log` to show you the op log, `show`/`diff` which work like their non-op versions, and `jj op restore` which is sorta like `git reset --hard HEAD@{whatever}` but for your whole repo state