Jujutsu Primer

(ethanlowman.com)

204 points | by renehsz 1 day ago

32 comments

  • danpalmer 1 day ago
    I've been using JJ almost exclusively for over 2 years now. It's great, it works fantastically with our rather large monorepo at work.

    However I mostly use it backing on to a custom VCS, not git. I can't wait to see some JJ-native forges that don't try to keep it compatible with git, I think there's a lot more benefits and more UX to be explored there!

    • ezst 1 day ago
      I doubt so, because not being compatible with the git repo format (and therefore requiring distinct hosting, therefore socially excluding from GitHub) is what slowly drove mercurial into obscurity, even though its UX was (and still is) superior to that of git (and JJ, which drew from it), not to mention the other aspects which made hg a much sounder choice on technical merits (e.g. very large monorepos), the users and decision makers both couldn't stand breaking away from the git repo format.
      • danpalmer 1 day ago
        I agree that this was a factor in Mercurial dying, but I'm not sure this holds today. Mercurial performed significantly worse than git, that was a factor at the time, but in 2026 the perception is that git doesn't perform well enough (see GitHub outages, GitLab writing on this topic, Anthropic developing their own VCS, etc). Even small teams I know (circa 10 committers) are finding Git to not scale to the speed they're working at now.

        JJ has the potential to be a substantial step forward in performance. This will depend on the backend to fully realise it, but a backend that prioritises scalability could vastly outperform git and GitHub's storage.

        I think in the post-Microsoft acquisition, post-Dear GitHub letter era, GitHub's shine has worn off. I see a lot more use of GitLab for open source, a lot more use of various other forges. I don't think it's a requirement for a thriving open source project in the way it was for ~2010-2020.

        • dotancohen 1 day ago
          You conflate Git and GitHub a few times here. I'm a heavy git user, almost never anywhere near GitHub.
          • danpalmer 1 day ago
            This is somewhat on purpose. For most people GitHub is most of their git experience. But even if it's not, GitHub represents the most mature attempt to scale git storage, and at this point it seems to be clear that it's not doing well at that, at this point it's likely that's not a git problem, but a GitHub problem. The fact that other large companies have migrated off git due to scalability issues is further evidence for that. Git's data model is just not designed for the scale of software engineering happening now.
            • dotancohen 1 day ago
              Pushing and pulling from a git instance without a working directory on a server is seriously fast and robust.

              Try `git init --bare --shared`. You'll never pay for GitHub again.

              • danpalmer 9 hours ago
                My point isn't that trivial git is slow, that's perfectly fast enough. My point is that when you've got a big repo, a bunch of committers, need multiple serving machines/replicas, consistency, etc, git is slow.

                GitHub is the best implementation of that which I have seen, and GitHub even started to get pretty slow on a repo with >100k commits.

                Git is breaking, and I don't know if there's any saving it at this point.

              • ezst 1 day ago
                now compare that to just `hg init` for the same effect. Git is so damn powerful!
                • dotancohen 21 hours ago
                  You actually could have the same effect as `hg init` with `git init`, but the command I mentioned leaves no working directory so uses less space on the server. Potentially hundreds of megs of disk space are worth a dozen keystrokes, no?
                  • ezst 20 hours ago
                    If you absolutely want nothing checked out, `hg update null`. Again "bare repos" are an absolutely unnecessary cognitive burden an UX papercut just like many things git.
                    • dotancohen 16 hours ago
                      You don't have to use bare repos, I just prefer them. You can use `git init` and ignore the working directory, just like you apparently [can] do in hg.
                      • ezst 9 hours ago
                        JFTR, it used to matter for push-ability whether it's bare or not, it appears to have changed in the recent years.
      • nvme0n1p1 1 day ago
        Compatibility helps with adoption, but it isn't absolutely required. Git wasn't compatible with the CVS repo format, but still became popular.
        • ezst 1 day ago
          Sure, but that was before the GitHub monopoly, the social/gamification of it, before the monoculture that ensued, and at a time when it was normal to cruise through the day using 2/3 distinct VCSes (being a FOSS contributor before 2010, you probably would use svn/git/hg/bzr on a daily basis and not need to RTFM for most routine commands like branching, checking in, merging and sharing a diff/series in one form or another).
      • eloisant 1 day ago
        Mercurial and Git arrived exactly at the same time, in 2005. Most people were using SVN (or some of them still on CVS).

        If Mercurial was better than Git it would have won the distributed versioning system war.

        I remember Mozilla picking Hg instead of Git to migrate from CVS, and most people were unhappy about it because they prefered git.

        • yjftsjthsd-h 1 day ago
          I don't think that follows. Even at the same time, social and network effects have impact. Git winning might be as simple as linux using it.
          • p_l 1 day ago
            Non trivial part was that GitHub had better UX than Hg-supporting forges.

            People learnt git to use GitHub

            • atombender 4 hours ago
              Git felt like it had "inevitable" momentum way before GitHub.

              In 2005 my company was using Darcs. We had previously used CVS and then Subversion. Darcs felt like finally the right, modern, decentralized version control system had arrived, even though there was no GitHub for it. Darcs was magical in ways that Git still can't measure up to.

              But arround me more and more colleagues were starting to use Git, which they gushed about as being the new cool thing. Git, at that time, was barely more than a very unfriendly set of commands with barely any documentation. But even before GitHub it seemed like "worse is better" was clearly winning over Darcs and the other new contenders.

              By circa 2007 we had switched over. The thing that really pushed us over was that Darcs had a huge, work-stopping bug that the authors could not resolve. Darcs 2 eventually made the bug less of a problem, but it was too late, and at that point it was even more niche than in 2005.

              GitHub was clearly instrumental in cementing Git's "monopoly" on version control. Once GitHub was out, the writing was on the wall.

              • p_l 3 hours ago
                As someone who also used Darcs, every time I had to deal with Darcs and git side by side I wished the Darcs project used Git too.

                Which is mostly a critique of how Darcs was badly implemented and trivial equivalent of "git pull" could tank a big server.

                From SVN, there was a lot to push towards Git because of speed, too.

                But all of those above were also arguments for Mercurial, and that's where GitHub is real divergence point IMHO

            • yjftsjthsd-h 1 day ago
              I originally thought to write "Git winning might be as simple as linux and github using it.", before I decided to shorten it:) Yes, I think that was a significant factor.
          • ezst 1 day ago
            not to mention that many at mozilla cried over the loss of mercurial, with some mozillians part-time mercurial contributors rolling-up their sleeves and putting their weight behind jj as a "lesser evil" kind of compromise.
        • letsseeok 1 day ago
          We're still on SVN. We exist.
          • hobo123 1 day ago
            I remember merges on SVN. It was horrible, and I was so happy when we finally migrated to git. Good riddance.
        • DrBazza 1 day ago
          Part of the problem was that businesses still wanted a centralized version control system. It's what they understand and need.

          At the time there were a couple of low-key Mercurial server solutions: bitbucket, and another I can' quite recall. And then there was Github.

          At the time it very much felt like the HN/Silicon Valley hype-cycle/publicity bandwagon jumped on Github. That's really what won 'the war'.

          It's a bit like saying, if betamax was better than VHS it would have one the video battles.

          Back in the day, Windows was still 'king' and Mercurial was Windows friendly, and git really wasn't, and that still wasn't quite enough.

        • BeetleB 1 day ago
          > If Mercurial was better than Git it would have won the distributed versioning system war.

          Ah, so Windows is better than Linux/UNIX and MacOS. Got it.

      • IshKebab 1 day ago
        Totally different situation IMO. Git and GitHub were not incumbents at the time. Mercurial mainly lost because it was overall worse than Git, ignoring network effects.
        • ezst 1 day ago
          You cannot decouple "VCS" (the component at the core of the project collaboration fabric) and "network effects". Too bad we don't have time machines: how many chose git over alternatives because "they've seen others doing it", without putting time and effort to weigh the pros and the cons? My observation is: a substantial amount.
    • pksunkara 10 hours ago
      I am trying to build a forge that supports both git and jj at the same time, https://juju.bi
    • jon-wood 1 day ago
      I'm not too bothered about the backing store but I really want to see some forges gain support for code review based on jj changes rather than git branches and commits. The Github model absolutely sucks if you're someone who likes to keep a coherent history because if you squash the resolution of PR comments into the parent commits nobody can see what changed between when the comments were made and now.

      Basing code review on changes and changesets would mean that the evolution of each change could be seen in isolation, which would also mean that you immediately do away with awkward workarounds like PR stacks.

    • jkbbwr 1 day ago
      Hey I took a crack at this I need to do some updates on it sometime but

      https://jjhub.dev/

      (I am the author)

  • nixpulvis 1 day ago
    I'm skeptical about the no staging area, but it seems just like a HEAD commit replaces that, which could be nice.

    I really don't like the automatic bookmark naming thing.

    I'm also skeptical about automatic rebasing, but having conflicts not block the process could be nice, I'll have to try it out on more complex trees.

    Also, I didn't see a section on workspaces, but I assume they basically do the right thing.

    • ozim 1 day ago
      Have to say staging area is one feature that makes people better programmers. Especially using GUI tooling to pick hunks or discard parts you don’t want to go to a commit was always super useful for me. (CLI of staging hunks is not convenient at all for me)

      I keep running into people who “just commit stuff” and they don’t know what they are doing.

      Downside is we are heading into direction where people don’t even read code anymore so I might be just old man screaming at the clouds or agents.

      • rbehrends 1 day ago
        To each their own, but I always saw the staging area as an anti-pattern that also needlessly complicated git's mental model.

        With the staging area, you don't even know if the commit builds if you commit selectively, and manual adding is error-prone.

        The traditional "clean" way has been to stash unwanted changes temporarily, then commit the rest.

        • coffeeindex 23 hours ago
          > With the staging area, you don’t even know if the commit builds if you commit selectively, and manual adding is error-prone.

          I get conceptually why it’s desired to have things build properly on every commit but I just haven’t seen people actually make use of that. In my team’s current code base, we have the commits in a given PR auto-squash down into one commit which I’ve liked quite a bit

          • nixpulvis 21 hours ago
            It's the lazy and pragmatic solution for those who aren't really comfortable with git / VCS.
        • ragall 19 hours ago
          > With the staging area, you don't even know if the commit builds if you commit selectively

          You should always use server-side CICD.

          > and manual adding is error-prone

          That's a UI problem. I've been manually selecting code with Magit for years and it's very effective.

          • rbehrends 17 hours ago
            > You should always use server-side CICD.

            First, server-side CI is usually only running for the last commit, so if you have a series of commits pushed at once, this doesn't really help.

            Second, it's not even so much about the validating a commit (which, for intermediate steps, it might not do), but so that each commit hangs together and a change as a logical unit doesn't exist partly in one and partly in another commit [1].

            Conceptually, the whole staging process flies in the face of the idea that a commit should represent an atomic repo change and feels more CVS-like.

            > That's a UI problem. I've been manually selecting code with Magit for years and it's very effective.

            There are two counterpoints I would like to make here. One is that if you need additional tooling to work around a problem in an existing tool, that does not mean the original tool does not have a problem.

            The other is that better tooling does not mean that the increased error rate from unnecessary manual steps goes away; it can mitigate it, but it does not do away with the consequences of e.g. inadvertent lapses of attention.

            And realistically, in most cases it is just unnecessary extra work for no good reason.

            [1] Mind you, there's the problem that commits are really used for two different things, one is to capture conceptual steps and one is to to do quick save of the repo state, and no existing VCS does a good job of reconciling these two different purposes.

            • ragall 11 hours ago
              > Second, it's not even so much about the validating a commit (which, for intermediate steps, it might not do), but so that each commit hangs together and a change as a logical unit doesn't exist partly in one and partly in another commit [1].

              That's what review is for.

              > Conceptually, the whole staging process flies in the face of the idea that a commit should represent an atomic repo change

              No it doesn't. The staging area is precisely what allows you to carefully build a commit. Before git, we had to do the same by backing up the modified files somewhere else and creating a commit, then bringing them back. I used to use CVS, then Subversion, then a mix of Darcs and Arch, before git finally solved it.

              > One is that if you need additional tooling to work around a problem in an existing tool

              You're assuming there's a problem. There isn't.

              > Mind you, there's the problem that commits are really used for two different things, one is to capture conceptual steps and one is to to do quick save of the repo state

              Using commits to save state is bad and I've forbidden it in my team. Jujutsu makes it more convenient so that uncommitted state is itself a special commit that gets pushed to the server, but the real solution is what Google's SrcFS does: workstations checkout code on top of a FUSE filesystems that really gets saved on the server side, so state can never get lost on a single machine.

              • ozim 7 hours ago
                That’s something I have the same thoughts on, because long time ago I used CVS/SVN and staging area with stashing was exactly the answer for what you wrote.

                Combined with stashing you can quickly build to see if the commit builds.

                Git supports all of it and people and jj are just complicating it by “let’s skip all of that and make a commit” because they don’t see it actually is simpler.

                I just see how in 5 years someone who would be used only to jj will come over and re-invent staging and stashing “because I want changes but I don’t want to make a commit”.

      • wmedrano 1 day ago
        I think jj is pretty good at this. You can use `jj squash -i` to move hunks to parent commit or `jj split to partition hunks into separate commits.
      • KingMob 1 day ago
        Think of it this way: you still have a staging area in jj, but now it's a commit instead of something unique and separate. There's zero obstacle to picking and discarding hunks with jj.
        • BeetleB 1 day ago
          > Think of it this way: you still have a staging area in jj, but now it's a commit instead of something unique and separate.

          Indeed. One nice thing about this is you can have a staging area for the staging area (repeat ad nauseum). It's not that unusual that I treat a commit as the staging area, and then I want to do something experimental on top of it, and make a new commit on top of my staging area and try things out there - ultimately to squash into my main staging commit.

          In my last job I gave a presentation on jj and I hammered this point. I said it's like git but with everything version controlled. The index/staging is version controlled. The stash is version controlled. Technically even things like setting/unsetting bookmarks, commit descriptions etc are version controlled.

        • ozim 1 day ago
          I do that for stash, I do not use stash for me it is commit or discard.
        • IshKebab 1 day ago
          Here's my current workflow:

          1. I write some code.

          2. I realise it makes sense to commit as two commits.

          3. I stage changes for the first commit & commit it.

          4. I stage the remaining changes and commit those.

          How would that work in JJ? I guess you do things in a different order somehow?

          • dieortin 1 day ago
            You would just use jj split to break the working commit into two, choosing which parts to put in which commit
            • IshKebab 21 hours ago
              Ah right so I can say "jj put this change into a new/existing commit before this one"?
              • bilkow 18 hours ago
                Yes, for new that's what `jj split -i` / `jj commit -i` do by default. For existing that's `jj squash -i`.

                `-i` makes it interactive (you select the changes you want in the parent, using a TUI), but you can also pass the list of files as arguments. You can also choose which commit you want to split (for split) or move from, to (for squash), etc, with arguments. More info on them here: https://docs.jj-vcs.dev/latest/cli-reference/#jj-split

              • SAI_Peregrinus 19 hours ago
                Yep. `jj split` says "take this change and put parts of it into a new change". `jj squash` says "take this change and put parts (or all) of it into an existing change".
          • nchmy 1 day ago
            Someone already said this, but you just use jj split. Either split the whole file or use interactive mode to split the exact lines. You could also use squash if you want to move it to an existing revision/commit.

            Jj makes it vastly more efficient and ergonomic to perform surgery across commits - no staging area to think about, remember, stumble over, etc. Conflicts don't stop the world.

            It's all dead simple if you use jjui - don't even need to learn any jj syntax

          • SAI_Peregrinus 19 hours ago
            For me, with JJ:

            1. I write some code.

            2. I realise it makes sense to commit as two commits.

            3. I run `jj split` to split it into two changes.

            4. I describe (add messages) to both commits, and push them.

          • orbisvicis 1 day ago
            For me:

            * working tree == in progress

            * staging area == finished

            How do can I split modifications to a single file into multiple commits? (In git)

            • ozim 23 hours ago
              You stage hunks, git add —patch which is not convenient so better to use GUI tools.
          • ssivark 1 day ago
            The stuff you wrote is always captured in a commit and never in some weird lingering (uncommitted) state.

            Treat the HEAD commit like your staging area. Split it as you will, pick stuff you like, remove stuff you don't want and push it to a different commit, etc. Feel free to rewrite history as you will (that you haven't exposed publicly, for others to depend on).

      • throawayonthe 1 day ago
        if anything i think jj encourages you to commit selectively by doing jj squash <options> / jj split and by enabling you to edit commits with no worry
      • yjftsjthsd-h 1 day ago
        I effectively skip staging by just doing e.g.

          git commit foo bar/
        
        To commit my changes to foo and bar/* but not baz. Also pairs well with -p.
      • breppp 1 day ago
        In jj you create a new commit for the staged parts, you can name it "wip: foobariating", and then the gui tooling allows you to move files between both commits, for me it's the equivalent of a staging area/stash that you can name
    • adamtulinius 1 day ago
      I've used jujutsu for maybe half a year by now.

      At first the auto-staging (or whatever it's called) is annoying. It sure is if one is used to dump random files in the repository, that haven't been ignored.

      After some time, I realised it gives a lot of freedom. Working on something but not in a workspace, and need to do something else for the day? Just jump somewhere else. Everything will still be there when you get back. In other words, it's hard to lose things by mistake. In those situations it's also cool to describe (name) the work being done, prior to making a normal commit. A bit odd but one can also push `@` to a remote (e.g. iterating on something and piggy backing on a CI-system), avoiding having to squash and then push.

      Having a stack of PR's, then rebasing it all to see a conflict, and only having to deal with it one is also magical.

      Moving bookmarks around can be annoying.

      Workspaces work fine, and there's two options:

      - the normal ones, where a full .git isn't created. That works fine, unless having tooling that expects the workspace to also work as a git repository, in which case ..

      - you can make the workspace collocated, less lightweight, but git tooling works

      • wry_discontent 1 day ago
        Jumping around has been the biggest thing to me. If I wanted to look at another branch real quick, I would've either done a worktree, another clone of the repo, or some bullshit commit like 'WIP' or something.

        JJ lets you freely move through the history.

    • jon-wood 1 day ago
      As others have said, the head commit is effectively a staging area, it just contains everything that you've done which you can then split/squash/rebase as you see fit. `jj split -i` felt like magic the first time I used it.

      Automatic bookmark naming is 100% cursed, I always name them, and also don't subscribe to this weird one commit per-bookmark/PR thing people seem to have adopted. You can use bookmarks just like git branches in practice.

      Rebasing is so much nicer than doing the same thing with git because its going to do its best to finish the job, then leave you with a coherent set of conflicts you can clean up one commit at a time. Its still conflict resolution, and it still sucks, but at least you feel less like you're fighting the tooling.

      Finally, workspaces exist and work reasonably well. Annoyingly Claude Code specifically has real trouble interacting with them, and last I tried in agent mode refused to accept that a jj workspace is just as valid a mechanism as a git workspace. They may have fixed that by now, its been a while since I tried.

    • Balinares 1 day ago
      Then imagine having as many staging areas as you want, stacked or in parallel branches or arbitrary combinations thereof with easy mechanisms to move chunks between them. That's Jujutsu.

      Git feels like running with leaden shoes by contrast.

    • dwattttt 1 day ago
      I have a good story around these features.

      At the start of the day, I resumed working on a feature; there's no staging, so modifications I make are all stored as the current change.

      Later that day I realised I needed to actually save the version of the feature that existed when I started work that morning.

      So into the evolog I go (`jj evolog`). It's a record of all commits that a change has been; I could scroll back through the recorded changes, find the first change made that day, and then 'jj new' to create a change that represents that work.

      It felt magical, to just be able to jump back to a project state that I didn't explicitly record, then save it.

      • zaphirplane 1 day ago
        I don’t get the excitement, it looks a lot like branching off a commit
        • y1n0 1 day ago
          As a sibling said it tracks snapshots that are taken every time you run a jj command. A pattern I follow is to keep a window open and ‘watch -n 1 jj log’ so that I can see the graph update in real-ish time when I’m navigating or shuffling commits. It also has the benefit of snapshotting any changes once per second. If nothing changed, no snapshot happens. It’s a nice backstop against forgetting to commit some earlier change that was later wiped out.

          The jj log graph is very nice visually in the terminal.

        • dwattttt 21 hours ago
          Other people mentioned it, but since it was what I did; I didn't commit the day before/that morning. I didn't realise I'd need that morning's version, I only realised that after mutating it.

          So it's the "oh no, I realise now that I needed to commit before I made all those changes" situation, but since the workspace gets snapshot/committed on every jj command, nothing was lost.

        • thek3nger 1 day ago
          The evolog doesn’t track explicit commits. It is a list of snapshots of the codebase. JJ creates a new snapshot every time you run a command (or edit a file, depending on how you configure it).
        • BeetleB 1 day ago
          Yes, but without having to tell it to branch off.

          One of the nice things about jj is you don't need to name a branch. You're just working on a graph. When you think you have something consistent and would like to give a name to it, you can do it (before or after the fact). But the lack of friction in creating a temporary new branch is amazing.

          If you used VCS before git and loved how easy branching is in git, this is the same feeling in jj, but now with git being the old, tedious way.

          • skydhash 1 day ago
            > One of the nice things about jj is you don't need to name a branch.

            Maybe it's due to different thinking process. But I can't think of doing a branch without knowing why I would need to do it, which also give me a quick indication of how I should name it. Everything is local anyway so I don't complicate stuff.

            • steveklabnik 23 hours ago
              You see the description of changes in your log, and so that's often good enough as a name. No need to give it a second one. Here's an example from a project of mine:

                  │ ○  lrvwrmqv steve@steveklabnik.com 2026-09-07 22:13:12 977b1ab7
                  │ │  harden running image identity fixtures
                  │ ○  vqmsmkup steve@steveklabnik.com 2026-09-07 22:13:12 bcd98591
                  ├─╯  add running compiler image identity
                  ◆  mxvotmyz steve@steveklabnik.com 2026-09-07 21:53:55 trunk e37a132e
                  │  satisfy the byte recovery Clippy gate
              
              It's nicer with color. Anyway, this is an anonymous branch, with two changes on it. "add running compiler image identity" and "harden running image identity fixtures" let me know what that branch is about, without needing to add an extra name onto the branch itself.
              • skydhash 21 hours ago
                I've just replied to another comment of yours

                https://news.ycombinator.com/item?id=50577902

                But the relevant bit to this is the following

                  I want tooling centered around the concept of a patch, not the concept of commits.
                
                Commits for me are settled patches. I don't go around editing commits that much (and I have the tooling to make it trivial). Because for me, the patch inside has served it purpose. When I found a new purpose for it, the context has already been changed, so even when it saved me a bit of typing, I had to look at it anew.

                So only the few commits around my current tasks are in flux. There's not a lot, so rebasing is very easy, even with the git cli. Same with editing a span of commits. It becomes the workspace and thus can easily be modified. Everything else is just on hold. That's why I like named branch. Because I look at it holistically instead of individual commits.

                Maybe your workflow is different, and you are always doing surgical treatment to a complicated tree. But I never needed to do so. These days I'm even leaning towards a single patch for a feature or a fix. Way easier for communication.

                EDIT

                reply slowed down by HN moderation.

                • steveklabnik 18 hours ago
                  I think the single commit case makes it even less of a need to name the branch, since the description is very much naming exactly what piece of work it is already.
    • silon42 1 day ago
      I don't mind auto commits too much, but auto adding files really doesn't work for me.

      I'd be OK if I had to immediately (blocking any operations) choose whether to add or (locally) ignore the file, but auto-add isn't for me.

      • nixpulvis 1 day ago
        Agreed, seems like we want this:

            jj config set --user snapshot.auto-track "none()"
    • eloisant 1 day ago
      Yes you can create an empty commit on the top of your branch, it works like a staging area.

      Or edit the commit if you just want to make a quick fix you know you'll want to squash immediately.

    • BeetleB 1 day ago
      > I really don't like the automatic bookmark naming thing.

      That's only when you're pushing, and you can always explicitly name it. I've never done an automatic bookmark.

      > I'm also skeptical about automatic rebasing

      Automatic rebasing is one of the best things about jj. I rely on it so much (just jump back to the commit with the bug and fix it right there) that I don't think I'd be happy with any version control system that doesn't have it.

      • nixpulvis 21 hours ago
        Yea, but it's not running the rebases that's hard, it's managing the conflicts.

        Does jj have something like git rerere?

        • SAI_Peregrinus 18 hours ago
          Yes, it does. I've never had to re-resolve the same conflict twice.
          • BeetleB 18 hours ago
            Same here. I'd totally forgotten about that pain!
    • sick_of_slop 1 day ago
      [dead]
  • pkuki 1 day ago
    Shameless plug, but a bit related to jj:)

    I recently created a project which utilizes FUSE to serve git files directly from object store without a checkout. Main motivation was to sepeedup a worktrees creation (I work on a huge monorepo). In my case it helps a lot - now I wait a second instead of a minute. But then I realised there are other interesting features which having vfs opened:

    - tree structure of related branches (simplest case of that are stacked PRs) which rebases itself

    - live preview of merge state or any node of such tree

    - on demand creation of a new branch which merges any of the existing ones very cheaply (e.g for a throwaway build check)

    - quick and simple comand which shows conflicting files between selected worktree and all others

    - agents gets notified about such conflicts when they happen

    I was able to design it in a way so git sees those virtual workspaces as normal worktrees, and all git commands works exactly as you would expect. So I think for some people, especially on the very big repositpries, it might solve a few problems they try to solve with jj.

    https://github.com/pkukielka/gitfold

    A few typical use cases: https://github.com/pkukielka/gitfold/blob/main/docs/guide.md

    • jauntywundrkind 1 day ago
      You made it much further with this effort than i did! https://github.com/rektide/jj-workfuse

      I think in truth I 50% of the reason I made it was because I was mad about Anthropic inventing a whole new vcs after blaming git clone speed. I also knew artifact-fs exists, which works lazily to get data on demand, which is cool. https://github.com/cloudflare/artifact-fs https://news.ycombinator.com/item?id=47792374

    • IshKebab 1 day ago
      There are quite a few of those projects already I'm pretty sure, e.g. GitFS.
      • pkuki 1 day ago
        FUSE isn't new, but GitFS, EdenFS and VFS for Git solve a different problem: lazy fetching from a server. A checkout is cheap until something reads it - e.g agent trying to run rg over the whole tree. That problem is solved in gitfold. Also gitfold does not need or try to change any existing git behavior, and is fully compatible with existing git binaries without any modifications. So while used technology is the same, approach is from completely different angle.
    • signa11 1 day ago
      > I recently created a project which utilizes FUSE to serve git files directly from object store without a checkout.

      this for some reason gives me clearcase vibes...shudder.

      • pkuki 1 day ago
        Ha, fair: ClearCase dynamic views were a filesystem too. The difference is that nothing is remote and git stays the source of truth. And it's a single binary that runs without root, tiny next to a behemoth like ClearCase.
  • tkz1312 1 day ago
    I'm fully onboard with the idea that git is horrible to learn and unfriendly for beginners, and also that jj is more convenient and a better UX. I do however struggle to find the point of it for me personally when I've suffered with git for long enough that it has become deeply familiar and very intuitive, and these days I mostly interact with it at a distance through a robot. I've yet to see anything which is for me personally compelling enough to make the effort to switch.
    • nchmy 1 day ago
      You are welcome to do whatever you like! But I do think that you're being unreasonable when you are deliberately using a less convenient tool, seemingly just for the sake of it.

      jj just makes everything so much easier. But more than that, it has capabilities that are not available in git - eg how it deals with conflicts. There's tons of guides and essays out there about all of this so I won't try to enumerate all the differences

      There would surely be some uncomfortable learning period, but it is worthwhile. jjui makes it that much easier too.

    • breakwaterlabs 23 hours ago
      > these days I mostly interact with it at a distance through a robot.

      Bad ergonomics-- terrible languages, clunky linters, complicated VCS-- can be offloaded to the clanker but the cost is still there. A clanker fighting to un-foobar a git repo is a clanker that spending tokens and coherence on not-the-thing-you-wanted.

      One of the best ways I have seen to "clear the head" of a robot is to provide better tooling that requires less cognitive burden-- for the user, or in markdown skills, its all the same.

      • SAI_Peregrinus 18 hours ago
        Another way to say it is that JJ keeps the context small, for both the user and a clanker. The mental model is simpler, it's just a DAG of changes. Unlike git there's nothing else tacked on, no extra staging area or stash to keep track of.
  • rootlocus 1 day ago
    None of the pages explain to me what jujutsu is or why I should choose it over git.
    • duggan 1 day ago
      Yeah, git never makes it to any list of tools I have a problem with.

      Clearly other people are delighted with jj though.

      Perhaps the value becomes clear on larger teams, big monorepos?

      • rgoulter 1 day ago
        My understanding of jj is that by-default gives you a good VCS workflow that otherwise takes a bit of discipline to use with git.

        - e.g. tracks everything by default; this is an advantage compared to "oops I forgot to check it in".

        - e.g. reworking feature branches is more natural in jj compared to rebasing in git.

        • duggan 1 day ago
          Ok, that does help connect the dots.

          I expect I've just internalized all these idiosyncrasies after so long.

      • LoganDark 1 day ago
        > Perhaps the value becomes clear on larger teams, big monorepos?

        I find it incredibly useful as an individual contributor opening many PRs on a single upstream project. I can rebase all my PRs onto new upstream changes in one go, I can easily keep the commit graph neat, I can easily squash changes down into specific PRs while keeping my working tree positioned after they all merge together. Really speeds up my workflow, it's awesome. And it's really cool that merge conflicts don't block operations. It's really limiting that git has only one active branch at a time.

        • duggan 1 day ago
          Interesting! Thanks for the explainer, speed / concurrent development makes sense; that's one area I probably subconsciously steer away from due to the awkwardness.
          • skydhash 1 day ago
            >> I find it incredibly useful as an individual contributor opening many PRs on a single upstream project

            > I probably subconsciously steer away from due to the awkwardness.

            I think if I need to rebase a PR enough while waiting for merge that it's a coordination issue and maybe too much churn in the codebase. There shouldn't be a need to do so. Not sure I'd blame git for that.

            • LoganDark 1 day ago
              I have to be the one to rebase my PR or my signature will become invalid. The only valid way to merge my commits is via fast-forward.

              (Do let me know if this has changed, but I've seen any other kind of merge result in the yellow "Unverified" status on GitHub, as I have the thing turned on that requires all commits from me to be signed with my own key.)

              • skydhash 23 hours ago
                That's just the surface concern. Why is the review time so large that you have multiple PRs ongoing? Why is the codebase churning you have conflicting changes that aren't trivial?
                • LoganDark 18 hours ago
                  No one is obligated to review PRs in a timely manner, nor stop development for me in particular. The entire point of a PR is that I put in all the work to maintain it as long as it is open, and eventually someone may get around to reviewing and potentially merging it. Upstreaming is a volunteer process.
                  • skydhash 16 hours ago
                    I thought it was in a team setting, especially with the requirement for signed commits.
                    • LoganDark 16 hours ago
                      Ah, no, I meant open-source upstream projects. I'm a (relatively...) prolific open-source contributor.
    • SAI_Peregrinus 18 hours ago
      It's a version control system that is git-compatible. It's got a simpler data model than git, and (IMO) nicer UI.

      WRT the model: JJ has a DAG of mutable changes. Git has a DAG of immutable commits, a mutable staging area, and a mutable stash.

    • rbehrends 1 day ago
      The single most compelling reason is probably `jj undo` and `jj redo`, with having a generally more consistent user interface and design being not far behind.

      The rest is probably a bit more of a tradeoff for many people in that jj like git also has a non-traditional mental model that you have to learn, with the difference that there is actually rhyme and reason behind jj's. But whether learning that (which can be a non-trivial effort) is worth it to you if you're already accustomed to git idiosyncrasies is a personal decision.

      • LoganDark 18 hours ago
        git has some rhyme and reason, but to me it's like the imperative to jj's declarative. jj feels like a React of version control, performing all the needed mutations automatically to arrive at the result you've specified, while git is still concerned about each individual mutation one at a time. There are layers you can add on top of git to achieve jj-like capability, and I often see people asking how jj has any benefit over such a layer.
  • boltzmann64 1 day ago
    i really don't understand jj. what is the point of deleting the useful stage and treating the worktree as the project, which contains your debug harness, compiler artefacts, build files, and other things that you generally don't want in your project. you have to either write a .gitignore counterpart for jj or manually remove them before committing.

    just treat your stage as the real project and worktree as some ephemeral sandbox. as you work build your index in stages by `git add -e` and removing your debug harness hunks. as soon as you reach a milestone, just commit and type your message when the context is fresh in your head.

    with jj, you work all day and finally when you are ready to commit, you now have to manually remove your debug harness, remove build artefacts, and reverse engineer your own code to write a commit message when you just want to go home.

    stop treating the stage as a implementation detail poking out into userspace. if it was just a implementation detail, linus wouldn't have defended it so fiercely.

    • bilkow 1 day ago
      I agree with you but I think that's more of a problem of the tutorials / docs out there than of the tool, which feel like they sell not reviewing your changes before committing as a selling point (that I disagree with). It seems like you just want what's usually called the "squash workflow"[0]. You create a new change on top `jj new`, when you want to "stage" changes, you can use move them to the parent commit by using `jj squash -i` to choose them interactively, or `jj squash path/to/file1 path/to/file2` to choose which files you want to move (similar to `git add`).

      In practice I usually just use `jj commit -i`, where you just select the files you want to keep there, edit / add the description (commit message) and a new change is created on top for your new working area.

      > compiler artefacts, build files

      I agree with my sibling those should be .gitignored and if not, yes those those may cause problems with `jj`

      > debug harness

      I think that works pretty well with `jj` actually. Let's say mid work you're interrupted and needs to check a an commit. `abc` is your current working copy and `def` is the commit you want to checkout. You can leave your harness behind (`jj new def`), do whatever you need there, then come back (`jj edit abc`). You can also bring your harness with you with `jj rebase -s @ -o def`. If it's something you commonly use, you can create a change for it and keep it as a parent, and then use a filter to prevent changes starting with a prefix (let's say local:) from being pushed. That said, there are some rough edges about keeping changes as a parent IMO (like having to set up command aliases or keep having to move it, depending on your workflow).

      [0] https://steveklabnik.github.io/jujutsu-tutorial/real-world-w...

      • boltzmann64 1 day ago
        if you are mid work and suddenly need to checkout something you checkout in a new worktree so that all your context remains intact. `git worktree` has been in stable since 2015.

        i have not used jj, but if you are introducing sqaush/new just you get what the stage does cleanly then you are implictly agreeing with the stage model.

        • bilkow 20 hours ago
          JJ also has worktrees (called workspaces), but some repositories require more setup (like .env, install dirs, etc), and just checking out ends up being simpler and faster.

          > i have not used jj, but if you are introducing sqaush/new just you get what the stage does cleanly then you are implictly agreeing with the stage model.

          Squash / new also do it cleanly, just like `git add -e` (I'm not sure what you mean with "cleanly", does it mean "as a special concept?"). And you're right, I agree with the stage model (that's most of the point of my comment!), and I personally think it works pretty well on jj.

        • SAI_Peregrinus 18 hours ago
          > you are introducing sqaush/new just you get what the stage does cleanly

          I think that's where I disagree with you. Git introduces the staging area (and stash) as separate concepts divorced from the DAG of changes. JJ just has the DAG, and nothing else. I'd say JJ is the cleaner model.

      • skydhash 1 day ago
        > Let's say mid work you're interrupted and needs to check a an commit. `abc` is your current working copy and `def` is the commit you want to checkout. You can leave your harness behind (`jj new def`), do whatever you need there, then come back (`jj edit abc`). You can also bring your harness with you with `jj rebase -s @ -o def`.

        It was not complicated with git either. If there was some important change that I didn't want to commit yet, I stash it. Same with experiments that contained valuable information. Then I can use stash apply whenever I want. Never had trouble jumping around the git graph.

        One key thing is that I find that conflicts are a very good signal for when the intent of the worktree at commit c clashes with the intent of patch p. Especially if you've designed the code to follow the single responsibility principle. I don't want to sweep this under the rug. Instead I want to solve it right away.

        A lot of jj advocates need to better highlight their workflows and why they think git was not doing well for them. I think there's too much focus on managing files instead of unit of changes (contained in patches).

        • steveklabnik 23 hours ago
          Same as the index, the stash is also just a commit. It's not that it's impossible to do any of this in git, it's that it's more orthogonal in jj. Commits, the stash, and the index are three features in git, but a single feature in jj. This also means you can bring all of the tools to use on your psudeo-index and psuedo-stash that you use to work with commits.
          • skydhash 23 hours ago
            My mental model is like this

            commits: clean patches that have been integrated somehow (even as a draft version in my local repo)

            index: patch in progress (very short lived as I usually add things and commit right after). It's an editing space.

            stash: valuable patches in terms of knowledge, but not relevant to any current task

            While they look similar, they have different purposes and so interact with different tools.

            I code for one purpose (and maybe get distracted for one thing or two) then goes on to clean up the patches and write a proper message. It's not a matter of adding and rejecting hunks. I also do edit them normally. Tooling is not a problem as I spend more time on reading and editing than on tool calls.

            Stashing is similar. The patches stored there are individuals, meaning I don't have to worry about dependency when I delete one. I also don't have to worry about location as there's just one stash concept.

            You can also find a way to do the same operation in jj, but I want tooling centered around the concept of a patch, not the concept of commits. jj make it awkward to work with patches.

            • steveklabnik 23 hours ago
              Sure, I agree with all of this. I just think jj supports doing all of this even easier than git does.
        • bilkow 19 hours ago
          > It was not complicated with git either.

          > A lot of jj advocates need to better highlight their workflows and why they think git was not doing well for them.

          Yes, I agree. Nowadays I use jj but I had the same feel before trying it, and I do think git usually works fine. What does it for me is just that it makes things simpler and there are fewer commands and special cases. I can use the same command I use to stage things and to move some changes from/to any commit (`jj squash -i`, adding `--from` and `--into` as needed). The same command I use to create a new commit is the one I use to merge (`jj new`, a merge is just a commit with more than one parent). It's super easy to change which commit a branch points to (`jj bookmark move`). With a few commands I can do most things and most of the time I just look at the single page CLI reference[0] to figure it out in a few minutes. I still use git when I need one of the (still) unsupported features, which in my case were submodules and LFS.

          > If there was some important change that I didn't want to commit yet, I stash it. Same with experiments that contained valuable information. Then I can use stash apply whenever I want. Never had trouble jumping around the git graph.

          Stash: for me, I just find it simpler with jj really. My "stash entries" show up in `jj log` just like everything else, and I immediately know in which parent it's based on. I can use the same commands to deal with the stash as I use for every commit, like I said in the previous paragraph, and I do not need to remember at which index the change was on the stash stack. I can also add a description to it if I want. Surely it's possible to do most of these in git, but in jj I already know how to do all of these as it's the same as any other commit.

          > One key thing is that I find that conflicts are a very good signal for when [...] I don't want to sweep this under the rug. Instead I want to solve it right away.

          Edit: ah, you're talking about the article. I also don't like leaving conflicts open and I do not use the edit workflow (where you edit commits in history directly). I will either: 1. create a new commit on top of the one I want to edit, then squash and immediately fix conflicts, or 2. work on the latest and squash all the way to the commit I want it on, then fix conflicts. TBF I don't think the way the article does it is too different from what you'd do with git, on git conflicts would only show when you do something like a rebase, a merge, maybe an amend. With the edit workflow it shows up when editing the files. At that point on git you're also "ignoring" the conflicts as you haven't merged / rebased yet.

          For me the advantage on `jj`'s conflict handling is that I'll create a new commit on top of the conflicted commit, fix the conflicts there, then review while squashing my fixes (or maybe even comparing to the conflicted commit's parent, with `jj diff --from @--`, this way I can see the whole picture of the fix.

    • rbehrends 1 day ago
      I found that annoying, too, until they introduced the snapshot.auto-track configuration option. Here's an example for a basic Rust project:

        [snapshot]
        auto-track = """
          root-glob:"{src,tests}/**/*.rs" |
          root-glob:"Cargo.*" |
          root-file:"README.md"
        """
      
      I set it to `snapshot.auto-track = "none()"` in the global config so that it is turned off by default and then selectively adjust it for a project.

      You can also leave it as `none()` and then manually add files as before.

      Note also that this has nothing to do with the staging area, but with selecting which files to add to a repo, which other VCSes can do just fine without having a staging area.

      In fact, selective auto-track plus not having to explicitly stage changes makes it less of a risk that you forget to add something.

      • boltzmann64 1 day ago
        i think forgetting to add something to stage is no worse than adding your debug to master/main because auto track added it. again, i appeal that please be deliberate about what you are adding. after all software engineering is a craft, so craft you commits.
        • steveklabnik 23 hours ago
          jj makes it easier to craft good commits than git does. This is specifically because the index is just another commit. You cannot apply your slice and dice tools to the index in git, but you can with jj, since the index is a commit like any other.
        • rbehrends 23 hours ago
          > i think forgetting to add something to stage is no worse than adding your debug to master/main because auto track added it.

          I agree with that, which is why I pointed you at the auto-track setting. I also think that automatically adding everything is a poor default.

          > after all software engineering is a craft, so craft you commits.

          I could not disagree more. Reliability dictates that you minimize the risk of errors, including those from having unnecessary manual steps for frequently repeated operations.

          My point here is especially git vs. pretty much any other VCS aside from jj, not git vs. jj; do not assume there are only two options here. Being explicit about adding files to a repo is generally a good idea. Having to repeat the process for already added files for every commit is just another opportunity for errors.

          And as I wrote in another comment [1], I actually consider the staging area an anti-pattern for unrelated reasons.

          [1] https://news.ycombinator.com/item?id=50573492

    • mirashii 1 day ago
      Stage or no, git or jj, not writing a gitignore once and never worrying about removing hunks as you described or filtering the list of unstaged files in your brain for debug artifacts seems like completely unnecessary cognitive load. I’ve never come across a project that staunchly refuses to gitignore the paths of build artifacts that shouldn’t be checked in. It’s basic hygiene to prevent accidents. I really can’t understand any reason to oppose doing so.
      • boltzmann64 1 day ago
        it only causes accident if you do git add --all. and my exact thesis is to be deliberate about what you commit.

        `git add -e` your files as you are satisfied (of course after remove your debug harness). this way you debug harness stays put in your sandbox/worktree and no harness leaks into your project which remains pristine. this is something that .gitignore cannot do. jj cannot. you have remove all your harness, TODOs and others just to commit and then add it back again. that just means your version control failed.

        and no, i am not advocating you should no add .gitignore.

        • mirashii 1 day ago
          > you have remove all your harness, TODOs and others just to commit and then add it back again

          No, you don't. You can split. You can untrack. You can change your auto-track configuration. There are many ways to deal with this other than having to remove them. You can be equally deliberate about what goes into your final commit.

    • BeetleB 1 day ago
      > i really don't understand jj. what is the point of deleting the useful stage

      You have a much more flexible stage in jj than in git. It's not gone anywhere. They just promoted it to first class and don't call it a stage.

      > you have to either write a .gitignore counterpart for jj or manually remove them before committing.

      I'll admit it is a pain. The one nice outcome, though, is that you now have everything in .gitignore and don't get "?" in your status.

      > just commit and type your message when the context is fresh in your head.

      The nice thing about jj is you don't need to worry about the "fresh in your head" part. You can write the commit message before you even begin, and modify it as you go along. You can commit things with no message (which I sort of use as staging), and much later, after several commits, go back and put in the message.

      • boltzmann64 1 day ago
        so jj devs reinvented the stage with extra steps and realize the foresight that linus had quarter century ago.
        • steveklabnik 23 hours ago
          It's fewer steps, because it is not an additional concept, just the same concept as the others. Better factored.
        • BeetleB 21 hours ago
          Fewer steps on average. When you don't need to be selective you don't need to do "git add", for example. Most of my commits when I used git were that way. Forcing me to do a git add each time added friction.

          jj gives you the best of both worlds. If you want the friction, you can have it - with no more commands than with git. If you don't want it, fewer commands. And if you want a fancier stage you can have that too.

  • pprotas 1 day ago
    JJ would be interesting to me pre-AI, but these days I don't run VCS commands myself so the problems JJ solves don't apply to me anymore
  • zahrevsky 1 day ago
    What I miss is a guide on how a good commit history should look like, ideally focused on real-world examples.

    There's lot's of jujutsu tutorials that teach you how to undo operations and write commit messages before the commit, but almost none cover what to do with all this power.

    It's easy to name some general principles like “it should be easy to read” but I don't think it helps, especially if you're a novice like me.

    • mtlynch 3 hours ago
    • jon-wood 1 day ago
      I think you're probably overthinking things. Split your changeset into a series of commits each of which encapsulates one step along the way to achieving the overall goal of your changeset.

      As an example, you might end up with "Refactor to facilitate adding feature X", "Data models for X", "API endpoints for X", "UI for X". Each of those would contain all the code/tests/documentation for each of those steps.

      The nice thing about jj is that it makes it really easy to have a bunch of messy commits locally as your bouncing around the place, followed by squashing/splitting things as appropriate. In practice that first refactor commit might only come into existence very late after you've built a bunch of endpoints and done some refactoring along the way.

    • epage 1 day ago
      This is my commit style guide I wrote up based on what I've seen that makes PRs easier to review: https://epage.github.io/dev/pr-style/
    • mhw 1 day ago
      The guide I usually point people at is https://mainmatter.com/blog/2021/05/26/keeping-a-clean-git-h... . It talks about git and the Fork GUI, which I find to be great for visualising what is going on in the repository, particularly for beginners who don't have a strong mental model of the commit graph.
    • jgtrosh 1 day ago
      Jujutsu tries to be nonprescriptibe about the end result, but my understanding of the megamerge strategy is that you want the powerful rebasing to help you manipulate many branches in parallel (fixes, features, etc), test them together, and end up with a linear history once accepted each is accepted. This isn't a real world example though.
    • hdjrudni 1 day ago
      Google offers some advice on how to write good commit messages: https://google.github.io/eng-practices/review/developer/cl-d...
    • dwattttt 1 day ago
      In practice I end up producing a branch where the commits are the kind of "ideal"; units of work that build on each other, but not interspersed with "fix something we didn't in notice in the commit a week ago".
    • rlecaro2 1 day ago
      If the only thing you're lacking is experience, try it out! You'll develop your own judgement along the way.

      jj gives you excellent tools to change your mind mid-way.

    • juped 1 day ago
      Follow the guide Git provides for contributing to itself! It's there in the source distribution, though I don't think the man pages.
  • textlapse 1 day ago
    Does this work well with LLM workflows? Any advantages over git for say Claude or GPT or Gemini to stage changes in a better way?
    • mhw 1 day ago
      Codex seems to do pretty well with jj in my experience. I often use it to do things like resolving the conflicts in a rebased stack. The two main issues I found were having to remind it to use jj instead of git in a colocated repository, and it getting stuck when some commands open the interactive hunk selector or an editor.

      I wrote a jj skill (https://github.com/mhw/jj-skill) that tries to address both of those issues, and explaining some higher-level workflows like the conflict resolution example I described above. It happily goes through the conflicts creating new commits off them, resolving the conflict, and then squashing the results.

    • VMG 1 day ago
      The LLMs I use seem to handle it (I'm not sure about the token efficiency though). It could actually be more token efficient because I'm not rebasing as often.

      Long-term I'm sure LLMs will have JJ in their training data.

      • pampa 1 day ago
        GLM-5.3 does seem to speak jj quite fluently and without consulting docs. Including complex codebase restructure and recovery of corrupted object storage.
    • nchmy 1 day ago
      I think all the models do pretty well with jj now. I just added instructions and a skill to make sure they always use jj rather than git commands.

      Only gap that I care about is jj workspaces<->git worktrees is not fully implemented. You can now auto create a worktree when you create a workspace, but not the reverse. There's prs for this though. I hope they get merged soon.

    • steveklabnik 23 hours ago
      The op log is really nice, separate from the staging stuff. Very easy to audit exactly what happened, and roll back if something is weird.

      Claude is also very good at fixing merge conflicts as well.

  • infinitezest 1 day ago
    Jj with jjui is such a nice way to work. I can have a bunch of agents going in different workspaces and easily rebase work using a visual tool. A small skill to help AI work with workspaces over worktrees is all I needed to smooth the seams.
    • elp 1 day ago
      Very much jjui!! Without it jj would still be nice but still a bit annoying.

      I just really with they would add :q as a quit option. Vi has given me brain damage.

  • Brajeshwar 1 day ago
    Someone here on HackerNews once advised me to just wing it and start using it. So, I started jj (Jujutsu) in small doses across my personal projects. I’m still at a super early stage, and my muscle memory is still stuck in Git.

    Totally guilty to have used AI (Claude Code) entirely to make this learning tool for me, and hopefully for others. There may be errors, please feel free to correct and point out.

    jj - taken through a small repository through 24 steps, drawn in 3D. Beside each step is the same step in Git.

    https://brajeshwar.com/misc/jj/

  • NothingAboutAny 1 day ago
    how does using something like this compare to just using a simple git-wrapper that does all the hard stuff for you (ala lazygit)? Is jujutsu worth learning a whole new workflow for?
    • danpalmer 1 day ago
      In my experience, git has a few workflows that work well, and you can wrap them to improve the UX. JJ on the other hand is just designed better – there are many more workflows that will work well in it, and you can mix and match them more effectively, and because it's better designed there's less need for wrappers to simplify the UX because the fundamentals are simpler.

      That said, I think JJ will get better when it's backing on to something that's designed from scratch rather than backing on to git and forges like Git(Hub|Lab) which really restrict it.

    • sundarurfriend 1 day ago
      I used jujutsu regularly for a while (several months) about a year ago. My conclusion, in short, was that the improvement over my lazygit based setup was small enough that it wasn't worth the friction and small annoyances of jj. I'd still recommend trying it if you have the bandwidth for it, it just isn't a strong recommend of "this is undoubtedly better".

      Longer version: if jj was what git had been originally, it would have saved millions of people a lot of pain and annoyance. It's definitely a better tool than git originally was. By now, though, git has gotten reasonably better, and the ecosystem around it has become polished enough, that the nicer, well-thought out UI of jj isn't as much of a slam dunk win anymore. It's still pretty good to work with, but there were enough papercuts for it to be not worth it for me: missing docs and features due to immaturity (presumably/hopefully to a lesser degree by now than back then), the friction of bookmarks interacting with branches in remote git forges, the fact that every throwaway file is committed right away (theoretically optional, practically assumed by every jj workflow out there) so you need to both ignore it and prune it out of history every time, there being `jj <command>`s and `jj git <command>`s that you need to remember which is which - all of these have understandable reasons and are small things, but overall added up to the fact that I felt myself dreading the jj-specific issues more than I enjoyed the upsides of it.

  • commandersaki 1 day ago
    I don't really see the point anymore of mastering jj or git; Claude does all the hard stuff for me.
    • pdpi 1 day ago
      JJ, using the squash workflow, is brilliant for working with Claude

      The workflow is straightforward: I create a named revision for the work I want to do, then an unnamed revision on top. I prompt Claude, changes land in the unnamed revision, I review those, squash the parts that I'm ready to accept, prompt some more to iterate on the parts that aren't up to par yet. Rinse and repeat until the topmost (unnamed) revision is empty.

      I instructed Claude that I use jj with the squash workflow, so it should never touch revisions with a non-empty description (I also needed to tell it to shut up about that check), and the whole thing flows pretty damn smoothly.

      • commandersaki 1 day ago
        I just tell Claude to fold changes in their respective commits when working on a feature branch. No need to do rebase edits or anything else really. I don't really have to think of what gymnastics it has to do to get there.
    • minraws 1 day ago
      But git cant undo claudes mistakes. jj can.
  • _betty_ 1 day ago
    tried jj once or twice, it just didn't quite click for me. Gitbutler seemed more intuitive, although more than likely less powerful.
  • ravieira 1 day ago
    I also strongly recommend this guide https://v5.chriskrycho.com/essays/jj-init/
  • sarthak-ag 1 day ago
    I wrote a piece on what specific advantages jj brings over git, and what kind of development workflows deserve it. Give it a read if you are debating internally whether jj deserves a place in your toolbox: https://sarthakag.bearblog.dev/from-git-to-jj-jujutsu/
  • Okkef 1 day ago
    While jujitsu is superior to git in many ways, I found it hard to get Claude and other agents to use it consistently and more effectively than git.

    Git and jj work trees are not interoperable, so any tool that assumes git forces you back. Looking at you, Claude app…

    • ajkavanagh 1 day ago
      Recently JJ supports colocated workspace/worktrees so you get a .git directory in the workspace so git is happy. Also workmux has initial support for JJ colocated workspaces and sesh (tmux session handler) also has experimental support. Whilst there are still some sharp edges, none of them are around data integrity, and I'm using it every day. YMMV.
      • Okkef 1 day ago
        Oooh thanks for pointing that out! :)
    • hdjrudni 1 day ago
      > I found it hard to get Claude and other agents to use it consistently and more effectively than git.

      Write yourself a very good JJ skill or reference file from your AGENTS.md.

      My LLMs struggled with it a lot too, but I slowly covered everything they were messing up and they haven't made a mistake in months now. Even when there are "divergent" issues, it knows how to recover now.

    • danpalmer 1 day ago
      Yeah it took me a while to get agents comfortable with it. Mostly I had access to Gemini, and 2.x and early 3.x models struggled. By 3.7 it was much better, and with all the 4 models it's a complete non-issue. Separately I (and others) worked on improving our JJ skills and they're in a much better place now with some scripts that wrap up more complex operations (e.g. maintaining file copy/move markers).

      This hasn't been an issue for me for a while now, and I've actually had Opus 5.5 and Gemini Hydrogen build and submit a 28 commit deep stack, with all the reviewing/rebasing/shifting around that entails.

      • p_l 1 day ago
        During late 3.x timeframe Google has been explicitly adding Jujutsu support across the agent stack in Antigravity, but it's not fully exposed unlike Git yet
        • danpalmer 1 day ago
          That's also true, the Antigravity harness may have been a contributing factor here. I use the internal Antigravity fork which uses JJ heavily because JJ is a core supported VCS interface for us.
          • p_l 1 day ago
            Lots of JJ in public antigravity changelogs, it just seems not wired into UI well
            • danpalmer 1 day ago
              That tracks. I've not used JJ in public Antigravity, only in the internal fork, and that's not JJ for git, but JJ for Piper, so I don't know how much commonality there is.
              • p_l 19 hours ago
                From my understanding it's pretty much one to one as far as understanding of JJ commands goes, but my setup has long lived JJ skills so I don't really know what's built in and what's not...
    • photios 1 day ago
      > I found it hard to get Claude and other agents to use it consistently and more effectively than git.

      That was the biggest hurdle for me too. I was a 2+ year jj user, then I had to switch back to git because of all the agentic tools relying on it.

      I recently went back to jj, after finding a decent skill [1] and discovering Emacs' majutsu plugin. Claude still tries to do a git command every once in a while, but it's a lot more bearable.

      [1] https://github.com/netresearch/jujutsu-workflow-skill/

      • FranGro78 1 day ago
        I use jj with open weight models and Claude Opus without much trouble, even without any explicit skill loaded for them - maybe they've made it into the training data? They seem to understand how the two differ conceptually and when told that the repo it is working in uses jj they stop using stash (or at least claim to).

        I can say this hasn't always been the case, and until about 2 (maybe 3?) months ago I would handle all the VCS related parts of the work. I would let the agents write code, which I've found less and less necessary to tweak as time has gone on, and write the commit messages and create the PRs by hand.

        My colleagues (who use git) let Claude write commit messages, but I find those awfully long-winded and my eyes just glaze over when I open their PRs - but to each their own I guess.

        At least the Claude commit messages are an improvement over the commit messages before - I gave up trying to get them to apply the recommendations of how to write good commit messages given in https://cbea.ms/git-commit/

    • indeyets 1 day ago
      I wrote an extensive skill some time ago. Works really nice https://codeberg.org/thisalex/jj-skill

      It's a tad opinionated: my agents are not allowed to push to external repos — but that's easy to change if you need

    • bigstrat2003 1 day ago
      You should really be doing your own commits anyway. It's not hard, and it's important to make sure you review what is going into the repo.
      • danpalmer 1 day ago
        I used to think this even just 6 months ago, but I no longer do. With the right prompting it's possible to get near-human results on commit chains. That said, I'm not suggesting you shouldn't review code, you absolutely should, it's just that I am fine letting agents manage the commits now.
    • jon-wood 1 day ago
      Use hooks. Prompts are for guiding an agent towards a goal. If you want it to never, ever, do a thing then write some hooks that detect an attempt to use git and refuse the tool use. "Is the `git` executable in this command line" is entirely deterministic and doesn't require throwing an LLM running on 15 GPUs at the problem.
    • BeetleB 1 day ago
      I have hooks that prevent repository modifications with git commands. And I have a global AGENTS.md file that says to prefer jujutsu if present.

      It works totally fine.

  • fridder 1 day ago
    I really would like to move my workflow to jujutsu but I have repos that use git-lfs. This has been open for over 4 years at this point: https://github.com/jj-vcs/jj/issues/80
  • tripple6 1 day ago
    Whatever (the) jj evangelists might say, I have yet to find a single use case (and I do mean a single one) where it has been useful to me. Any workflow they propose can easily be implemented with ordinary scripts. I understand that for "ordinary users" who can't tell Git's index apart from a remote repository, scripting that stuff is a pain. But I can't stop being surprised by the tenacity of people who fully understand that they could have implemented jj as an extension to Git itself, literally like git-jj extensions, yet chose to rewrite it from scratch and market it as a Git replacement. Well, a lot of time and effort has been spent in the wrong direction. But then again is that anything new in software engineering?
  • ionwake 1 day ago
    Is Domain Expansion planned?
  • soon_to_be_sb 1 day ago
    I have made my peace with git.

    But I still miss the number commit references from mercurial...

  • nelaggy 1 day ago
    jj is great, we use it a lot and we've hijacked it to make a decision-management/context-management system [0]. it's also generally very useful for keeping commit history clean and the squash workflow is good for progressively iterating with ai-written code, since you can squash to preserve the good parts and get agents to build on that.

    [0]: https://github.com/edawise/deccy-cli

  • bel8 1 day ago
    sadly jj doesn't have critical mass to "just work" like git does with LLMs.

    I proposed it and the team rejected saying jj solves a problem that was solved by LLMs and git, and that it would introduce paper cuts to our workflow.

    • wry_discontent 1 day ago
      huh? I have no issues with Claude and JJ. Git can do all the same stuff, since it's git under the hood, but using JJ encourages Claude to rewrite the commits. Which is good for us cause review is our bottleneck.
      • joshka 17 hours ago
        Can you get good diffs in the UI, for every turn, and never run into detached head stuff, assumptions about git etc. Does creating threads have to be told not to make worktrees? Do you have to tell it not to make temporary clones because it wigs out about uncommitted files in the current folder. This is just a small sampling of problems you get with using Claude / Codex with JJ. In general, tooling that assumes git makes design choices based on that which are just a little wrong.

        JJ is much better, and I want the tooling to support it better, but it's not there yet in general.

      • bel8 1 day ago
        Interesting. Did you have to instruct Claude.md or perhaps a skill to help Claude?

        By default it ignores jj for me and just uses git. The team wasn't eager to add more to the context.

        • steveklabnik 1 day ago
          You don’t need to a skill. You do have to ask it to use it.
        • yuzzuwo 5 hours ago
          [dead]
  • patata3000 17 hours ago
    Is it adapted for highly parallel agents changes?
  • herodoturtle 1 day ago
    Nice to see a minimal alternative to git.

    Also I’m sure there’s a joke in here about rollbacks.

  • meling 1 day ago
    Have anyone tried jj together with gh stack?
  • wawaWiWa2 1 day ago
    Is that syntactic suger?
  • mono442 1 day ago
    It seems like a good usability upgrade to git but a few years too late. I don't even remember how to use git anymore since the only thing I do manually is pushing to and pulling from the remote repo.
  • esseph 1 day ago
    Every time I see this thing I read the name wrong and it's driving me insane.
  • zhuanxyz 1 day ago
    [flagged]
  • mesm7903 1 day ago
    [flagged]
  • laruss5 1 day ago
    [flagged]