TE
科技回声
首页24小时热榜最新最佳问答展示工作
GitHubTwitter
首页

科技回声

基于 Next.js 构建的科技新闻平台,提供全球科技新闻和讨论内容。

GitHubTwitter

首页

首页最新最佳问答展示工作

资源链接

HackerNews API原版 HackerNewsNext.js

© 2025 科技回声. 版权所有。

jj init – getting serious about replacing Git with Jujutsu

142 点作者 chriskrycho超过 1 年前

23 条评论

caymanjim超过 1 年前
I can&#x27;t stand Git. The points the author makes in the intro are true. Developers learn just enough Git to do their jobs, which is unfortunately more Git than they actually understand. I&#x27;m including myself in this. I&#x27;ve been using Git for nearly 20 years (since the very beginning), and I still can&#x27;t accomplish anything more than the most basic things without reading documentation and hitting up the net for help. Even if I stick with simple operations, I can get in over my head. WTF is &quot;detached HEAD&quot;? I&#x27;ve looked it up dozens of times, and as soon as I get past whatever I&#x27;m working on, I forget what it means. I don&#x27;t know what the reflog is, other than that it has to do with some dark internals. Resolving merge conflicts during a rebase is a clusterfuck. And on any team I&#x27;ve ever worked on, the branch history is a nightmare to look at.<p>So I clicked on this link with the hope that it might be a kinder, simpler VCS. Especially after the article author talked about how bad Git&#x27;s CLI is and how much better Jujutsu&#x27;s is. But it looks like it&#x27;s just as much of an overcomplicated clusterfuck, and since it&#x27;s built on top of Git, you still get to experience all the pain of Git if anything goes wrong. And I wonder what kind of frightening scenario occurs when some contributors use Jujutsu and some use Git.<p>I understand that Git is powerful, and many of its features are valuable for large teams working on enormous projects (like the Linux kernel it was invented to manage). Hardly anyone needs that, though. I want a dead simple VCS for small project use that doesn&#x27;t come with so many footguns. I know simpler VCS exists, but without wide adoption, GitHub-like repos, and tooling support, using Git is still the path of least resistance.
评论 #39237247 未加载
评论 #39238464 未加载
评论 #39237196 未加载
评论 #39238287 未加载
评论 #39237477 未加载
评论 #39238391 未加载
评论 #39240450 未加载
评论 #39237095 未加载
reactordev超过 1 年前
The issue with people learning git is they learn all this construction around it without actually learning what <i>it</i> is. Branches aren’t real, it’s just a series of commits in time. Like a blockchain, the sha’s must match the previous (that forms the line&#x2F;branch&#x2F;tree&#x2F;root&#x2F;wtf ever). A HEAD is the end of that line. A detached head is when you have checked out a sha that isn’t the end. Once you throw out the concepts of branches and things, that they are just labels, like tags, moments in time with a previous moment in time. HEAD~1 goes back one node from the head, HEAD~5 will go back 5. You see? It’s easy, it’s simple, it’s not hard. You can <i>revert</i>, you can —amend, you can even <i>stash</i> your changes
评论 #39237908 未加载
评论 #39237643 未加载
k8svet超过 1 年前
I love &#x27;jj&#x27;. I would easily bet on it if I could. I know it&#x27;s HN and the criticism is almost a badge of honor, but I really hope people try it out.<p>I also use `jj` without anyone else knowing. I get to smile a relieved smile when coworkers talk about making mistakes with git rebase&#x2F;reset -f&#x2F;stash. I don&#x27;t sweat stacked patch sets. I never, ever, <i>ever</i> lose work. Ever. Never. Not even in my worst fat-finger, because of the oplog.<p>It&#x27;s <i>really</i> good. Please form your own opinion from trying it. I also find the article a bit too lengthy to easily digest.
memco超过 1 年前
Lots to digest here! I have been keeping an eye on Pijul so it is cool to see some of its features implemented in jj. Sapling[0], similarly, is a new VCS tool out there which can work with a git repo. It also has anonymous branches, no staging area, supports stacked commits and can track the history of a commit over time. I&#x27;ve been using a similar workflow to the article&#x27;s author: git with a UI to handle commits of hunks of a file to group related changes. My working branch often has unrelated changes that get tossed from branch to branch as I am able to commit. I haven&#x27;t figured out where these new tools fit into my workflow yet, but I am glad there&#x27;s new options that will help making working on a project more flexible and organized.<p>[0]: <a href="https:&#x2F;&#x2F;sapling-scm.com" rel="nofollow">https:&#x2F;&#x2F;sapling-scm.com</a>
评论 #39243324 未加载
评论 #39238756 未加载
评论 #39267566 未加载
actinium226超过 1 年前
You had me until the part with the log. You didn&#x27;t show the log, you simply explained how the jj log is confusing and not intuitive at first, and then there was a dive into some functional topics and an explanation of syntax (all while we haven&#x27;t seen the log) and some more shitting on git.<p>By the time I got to the changes section I was a bit too tired to keep reading.
评论 #39237653 未加载
bvrmn超过 1 年前
Complains about Git&#x27;s tag&#x2F;branches difference is a high chance author left Mercurial boat before they made proper branches.<p>BTW jj&#x27;s documentation does a better job explaining what&#x27;s the revs and changes are.<p>My only grudge with jj&#x27;s CLI it uses `-r` to specify first class entities. Git here does rare proper thing and uses positional args for commits and ranges.
crotchfire超过 1 年前
Wake me when they upstream it.<p>I can&#x27;t afford to invest in Google&#x27;s soon-to-be-abandonware projects.
评论 #39236831 未加载
Arnavion超过 1 年前
I&#x27;m surprised to see an alternative git frontend that doesn&#x27;t immediately drop the index for being &quot;too complicated&quot;, which in turn makes me drop the alternative git frontend for being &quot;too simplistic&quot;. I might try this one out.
评论 #39236546 未加载
评论 #39236827 未加载
lanza超过 1 年前
I love the ideas of jj but `jj split` is just an awful workflow. Splitting commits is too important of a feature to get right and jj gets it really wrong.
评论 #39237664 未加载
mgaudet超过 1 年前
I stumbled a bit using jj on a big repo [1], but I too am very interested in seeing it grow and evolve.<p>I plan to return to my experiment sometime, would love tips on large repos and making it more manageable.<p>[1]: <a href="https:&#x2F;&#x2F;www.mgaudet.ca&#x2F;technical&#x2F;2023&#x2F;11&#x2F;23&#x2F;exploring-jujitsu-jj" rel="nofollow">https:&#x2F;&#x2F;www.mgaudet.ca&#x2F;technical&#x2F;2023&#x2F;11&#x2F;23&#x2F;exploring-jujits...</a>
评论 #39236991 未加载
andrscyv超过 1 年前
I don&#x27;t mean to be mean, but it takes too long to get to the point:(
forrestthewoods超过 1 年前
Now it just needs a VFS so it can seamlessly work with large binary files.<p>Maybe it has some support for this already since it apparently works with Google’s internal monorepo? I can’t tell what the story there is.
amluto超过 1 年前
In “REVISIONS AND REVSETS”, you say “Revisions are the fundamental elements of changes in Jujutsu, not “commits” as in Git. But then you proceed to use “revision” and “commit” apparently interchangeably, and you don’t explain whether there is a difference.<p>You also lost me a bit on “change”. What is a change? If I modify a change, does it keep the same id? What if I send you a change and then modify it? At what point are <i>changes</i> immutable? What if I end up with two changes with the same id that aren’t the same change in my repo? The asciinema casts might have helped a bit, but the lack of scrolling or an easy scrubber makes it <i>really</i> hard to follow.
评论 #39237859 未加载
steveklabnik超过 1 年前
I keep hearing things about jj being excellent, but haven&#x27;t actually tried it. My brain is very git wired at this point, but when you keep hearing good things...
评论 #39235875 未加载
评论 #39235614 未加载
xedrac超过 1 年前
This looks interesting, and I will try it out, but I don&#x27;t feel any friction using git directly. The only exception is rebasing in some situations can be very annoying, and git LFS. How does JJ deal with submodules, subtrees, and LFS objects?
krupan超过 1 年前
&quot;Maybe the little bit of extra friction when you do want to push a branch is worth it for all the times you do not have to consciously move a branch backwards to avoid pushing changes you are not yet ready to share.&quot;<p>Very True.<p>This whole article really makes me miss mercurial. No need to create branches all the time, very rarely needing rebase -i, revsets, simple commands, those were the days! I&#x27;m almost afraid to give jj a try because I&#x27;ll fall in love and probably lose it again and have to go back to git
MattPalmer1086超过 1 年前
Ironically, it says that the problem with git is you have to internalise it&#x27;s model to use it effectively. But then describes JJ in terms of how it relates to what git does.<p>Talks about how it uses revisions not commits or something, but never really explains why it&#x27;s good, just more that it&#x27;s different to git.<p>So I think this is probably a very good article for someone who actually knows git, but isn&#x27;t very good for the users he says would most benefit from it!
multani超过 1 年前
Interesting discussion about `jj split` and how it opens up a GUI tool to select what changes you want to pick.<p>I&#x27;m using `git gui` <i>a lot</i>, I think about everydays, to pick up exact what I want to commit or amend my current work. It&#x27;s not a very fancy tool, but it ships with git by default and I feel it&#x27;s really underused and could actually make people&#x27;s life easier for editing undergoing work...
johnea超过 1 年前
What a waste of time. GIT works fine! This is a solution in search of a problem.<p>Detached HEAD and all, it&#x27;s not that complicated to use.<p>When you come up with a replacement for javascript, then I&#x27;ll be interestted...
评论 #39256508 未加载
m3kw9超过 1 年前
Git bisect, reflog useful but really a pain to use on the command line. There should be a GUI first class citizen for next gen source repos. You build the gui for every command you add.
ayberk超过 1 年前
I hope they change the binary name since &quot;jj&quot; is a common &lt;ESC&gt; binding for vim users :)
评论 #39236771 未加载
评论 #39236906 未加载
评论 #39236969 未加载
评论 #39236770 未加载
barlog超过 1 年前
呪術 (Jujutsu) the name is!<p>Jujutsu is a very meaningful and good name for VCS.
评论 #39237506 未加载
评论 #39238043 未加载
barlog超过 1 年前
呪術