Git 2.55 Lands with Big Speedups for Large Linux Repositories

Git 2.55 adds Linux support for its built-in FSMonitor daemon, helping large repositories avoid costly working-tree scans.

The Git project has released Git 2.55, introducing performance enhancements, workflow improvements, and new experimental commands to the world’s most widely used version control system.

For Linux users, the most notable feature is support for Git’s built-in filesystem monitor daemon. Previously, Git’s built-in FSMonitor daemon was available only on macOS and Windows. Git 2.55 changes this by adding Linux support and leveraging the kernel’s inotify subsystem to track filesystem changes.

This is expected to accelerate commands such as git status in large repositories. Rather than scanning the entire working tree, Git queries the monitor daemon for file change information.

One Linux-specific consideration is that the implementation uses one inotify watch per directory. Very large repositories may require increasing the fs.inotify.max_user_watches limit. FSMonitor support for network-mounted repositories remains opt-in.

Git 2.55 also introduces improvements to repository maintenance, particularly for large projects. The release enables git repack to write incremental multi-pack index chains using git repack --write-midx=incremental.

Git 2.55 also introduces a new experimental git history fixup <commit> command, which allows users to apply staged changes directly to an earlier commit and replay subsequent commits on top.

This provides a more direct alternative to the git commit --fixup and git rebase --autosquash workflow. However, the command remains experimental and conservative; if applying the staged change would cause a conflict, Git aborts rather than leaving the user in a complex rewrite state.

Configured hooks are also improved in this release. Git 2.54 introduced config-based hooks, allowing hooks to be defined in Git configuration rather than only as executable files in the hooks directory. Now, Git 2.55 extends this by enabling compatible configured hooks to run in parallel.

For example, independent pre-commit checks such as linting and unit tests can now run concurrently if they are marked safe for parallel execution. Hooks that depend on shared state, such as those inspecting the index or working tree, continue to run serially.

Performance improvements extend to reachability bitmap generation, enabling Git to answer object-reachability queries faster during operations such as repacking. Benchmarks cited in the release coverage show bitmap generation time in one large repository decreased from about 612 seconds to 294 seconds.

Partial clone and filtered-pack workflows benefit from enhancements to git pack-objects --path-walk. In Git 2.55, this mode can be combined with filters such as blob:none, blob:limit=<n>, tree:0, and others.

In addition to those mentioned above, several other minor changes are included. More specifically, Git now masks most terminal control characters in remote sideband output by default, decreasing the risk of confusing or unwanted terminal behavior during operations such as git push, while still allowing ANSI color sequences.

Moreover, the git checkout -m command is now safer. When switching branches with local edits, Git uses an internal autostash to save conflicted changes, allowing them to be reapplied later rather than requiring immediate resolution.

Support for pushing to remote groups is another addition in this release. This feature simplifies publishing the same branch to multiple remotes, such as a main host and mirrors. Users can define a group of remotes and push to all with a single command.

For users who rely on visual history output, git log --graph now includes a --graph-lane-limit=<n> option. This limits the width of the graph, replacing lanes beyond the limit with ~, making wide histories more readable in the terminal.

Finally, Git 2.55 introduces a --max-count-oldest=<n> option for git rev-list and the git log family of commands. Unlike the -n option, which selects the most recent commits, this option selects the oldest commits in a range without shell-side post-processing.

For additional details, see the official announcement.

Bobby Borisov

Bobby Borisov

Bobby, an editor-in-chief at Linuxiac, is a Linux professional with over 20 years of experience. With a strong focus on Linux and open-source software, he has worked as a Senior Linux System Administrator, Software Developer, and DevOps Engineer for small and large multinational companies.

Leave a Reply

Your email address will not be published. Required fields are marked *