I'm daily driving Jujutsu, and maybe you should too
Drew DeVault shares his positive experience with Jujutsu, a Git frontend for power users, enhancing workflows despite some limitations, including missing features and a restrictive Contributor License Agreement.
Read original articleDrew DeVault shares his positive experience with Jujutsu, a version control system that serves as a frontend for Git. Initially skeptical due to past experiences with similar tools, he found Jujutsu's approach refreshing as it caters to power users rather than simplifying the interface for beginners. DeVault highlights how Jujutsu enhances his workflow, particularly through its command for squashing commits, which allows for seamless editing of commit history without the need for multiple Git commands. Despite his enthusiasm, he notes some limitations, including the lack of support for the git send-email workflow and a grep command. Additionally, he expresses concern over the requirement for contributors to sign Google's Contributor License Agreement (CLA), which he finds restrictive. Despite these criticisms, DeVault has adopted Jujutsu for personal use and is willing to maintain patches until the CLA issue is resolved.
- Jujutsu is a frontend for Git aimed at improving the user experience for power users.
- The tool simplifies complex workflows, making it easier to edit commit history.
- DeVault identifies limitations, including missing features and the requirement to sign a CLA.
- He remains committed to using Jujutsu while addressing its shortcomings through personal patches.
- The author encourages collaboration on patches without signing the CLA.
Related
A Better Merge Workflow with Jujutsu
A new merge workflow using Jujutsu, a modern VCS compatible with Git, introduces The Austin™ Mega Merge Strategy®. It simplifies merge commits, amending commits, and selecting commits efficiently, enhancing collaboration and code review processes with advanced commit graph manipulation.
Jujutsu: A Next Generation Replacement for Git
Jujutsu, an experimental version control system by Martin von Zweigbergk, offers Git compatibility, simplified commits, effective conflict handling, and features like automatic rebasing. Despite being in active development with some limitations, it shows promise for revolutionizing version control.
Jujutsu (jj), a Git compatible VCS
Jujutsu (jj) is a new Git-compatible version control system that simplifies workflows with a user-friendly interface, focusing on changesets. It is still under development, with some features lacking.
Git and Jujutsu: In Miniature
The article compares Git and Jujutsu in managing legacy code changes, highlighting Jujutsu's simplicity and efficiency in handling commits and tests, reducing cognitive load compared to Git's complexity.
Jujutsu: A Haven for Mercurial Users at Mozilla
Jujutsu is a new version control system for users transitioning from Mercurial to Git, integrating Git as a backend, enhancing features, and simplifying operations while retaining familiar concepts.
With git I can just `git add --patch` and skip over these at commit time (which I like, since I review my own code as I'm staging it), but jj doesn't have the index and pushes you to commit all changes by default. I know there are workarounds like `jj split` but it ended up being more work than git, where I can just not add those changes in the first place.
Unsure why he hasn't gotten a response but last I heard on this is they are focusing on defining their google-independent governance before which will give them room to address CLA's.
https://web.archive.org/web/20241212125937/https://drewdevau...
Didn't bother looking further into it, not sure if this is a technical or ideological choice. Otherwise it reminded me about all the best parts of mercurial and git branchless. Pretty excited to get Fig-esque features in my external projects.
Now, I just need some GUI indicator or CLI prompt to ensure I don't lose track and I'm good to go!
[snapshot]
auto-track = "none()"
I can already work extremely fast in Git by using bash aliases and my workflow.
This might be useful for those starting out.
One problem I've had recently is that I've wanted to store a large JSON file on GitHub (that's, importantly, modified slightly each commit), but with indentation it's over 100mb so GitHub doesn't allow it. I can strip out the indentation and that takes it down to 60mb or so, but the large objects are still in git history so they get rejected, so evidently I need to rewrite the git history.
Unfortunately, if you just take an old commit, strip the indentation from the JSON and try to rebase all the other commits on top of that, it'll fail as git treats each commit as a patch and the patches to the unindented JSON don't make sense. What I really want is to for git to treat each commit as a repository state, so that removing indentation from the state at commit A means that the patch for commit B adds all the indentation, and then I can just write a loop that rewrites each commit state. This seems like something that there should be better tooling for, I mean `git filter-branch` exists but I don't think it works for this usecase.
Edit:
Here’s what chatgpt suggests (for rust code):
```python
import os
import subprocess
def reformat_file(repo, commit, file_name):
# Check if the file exists in this commit
if os.path.isfile(file_name):
# Run cargo fmt to format the file
subprocess.run(["cargo", "fmt"], check=True)
# Stage the changes
subprocess.run(["git", "add", file_name], check=True)
def main(repo):
file_to_fix = "path/to/your/file.rs"
repo.filter_commit(reformat_file, file_to_fix)
```And running with `git filter-repo --path path/to/your/file.rs --replace-callback reformat.py`. Ridiculous complicated.
So git has a notes feature, this is a simple note attached to a commit. It's intended for adding extra context to commit messages without changing the commit hash. Then there is a gitconfig for having these notes _follow_ the commit through rewrites such as rebases, squashes, amends, etc,.
All this together means that you write the branch name that you want in the note, use the git notes commands to two-way map this to the commit. Wrap this all in a git alias and it's golden.
Related
A Better Merge Workflow with Jujutsu
A new merge workflow using Jujutsu, a modern VCS compatible with Git, introduces The Austin™ Mega Merge Strategy®. It simplifies merge commits, amending commits, and selecting commits efficiently, enhancing collaboration and code review processes with advanced commit graph manipulation.
Jujutsu: A Next Generation Replacement for Git
Jujutsu, an experimental version control system by Martin von Zweigbergk, offers Git compatibility, simplified commits, effective conflict handling, and features like automatic rebasing. Despite being in active development with some limitations, it shows promise for revolutionizing version control.
Jujutsu (jj), a Git compatible VCS
Jujutsu (jj) is a new Git-compatible version control system that simplifies workflows with a user-friendly interface, focusing on changesets. It is still under development, with some features lacking.
Git and Jujutsu: In Miniature
The article compares Git and Jujutsu in managing legacy code changes, highlighting Jujutsu's simplicity and efficiency in handling commits and tests, reducing cognitive load compared to Git's complexity.
Jujutsu: A Haven for Mercurial Users at Mozilla
Jujutsu is a new version control system for users transitioning from Mercurial to Git, integrating Git as a backend, enhancing features, and simplifying operations while retaining familiar concepts.