2 comments

  • tensegrist5 minutes ago
    For what it&#x27;s worth, I&#x27;ve been doing basically this with magit for years now, sometimes with the two-commit setup but usually just using the index plus top commit instead. It&#x27;s not as slick, though, so this is on my list of things to try out when I give jj a spin eventually.<p>`c F` in the magit menu squashes staged changes directly into a commit in the log, and `c e` amends (which is to say squashing into the tip). So in this case I&#x27;d hit `s` to stage, and either `c e` or `c F j C-c C-c` (fixup, move one item down to get to HEAD^, confirm) — both of which are practically atomic operations for me at this point.
  • pzmarzly5 minutes ago
    I haven&#x27;t tested it, but this should be slightly simpler, and work better for subsequent review iterations (reviewing what changed once PR is updated):<p><pre><code> jj new main -m review jj new -m pr jj git fetch jj restore --from=big-change@origin . </code></pre> Then keep squashing from `pr` to `review` as described in the article. When the PR gets a new version, rerun the last 2 commands.