[git] - Fixing installation from source with new version 2.55.0#1678
Merged
abdurriq merged 1 commit intoJun 30, 2026
Merged
Conversation
abdurriq
approved these changes
Jun 30, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Starting with Git 2.55.0, the upstream build system enables Rust by default. As a result, the
gitfeature's "from source" build (src/git/install.sh) now fails when it tries to compile the latest Git on images that don't ship a Rust toolchain.This PR fixes installation from source by explicitly opting out of Rust during the build (
NO_RUST=YesPlease), restoring successful builds forlatest/current/ltsand any pinned>= 2.55.0version across all supported distros.Reference: What's new in Git 2.55.0? — Evolution of Rust in the Git codebase
Problem
The
gitfeature builds Git from source for non-OS-provided versions. Because this feature auto-detects and installs the latest stable Git, it began picking up2.55.0, and the build now fails on images without a Rust toolchain — which is the case for the dependency sets installed ininstall.sh(Debian/Ubuntu, Alpine, and RHEL/Fedora/Mariner). None of these install Rust, so the default Rust-enabled build cannot complete.Changes
src/git/install.sh— AddNO_RUST=YesPleaseto thegit_optionspassed tomake, so the source build keeps working without requiring a Rust toolchain:src/git/devcontainer-feature.json— Bump the feature version1.3.5→1.3.6.Why opt out instead of installing Rust?
Adding a full Rust toolchain to every build would significantly increase image build time and footprint across all supported distros, for a feature whose purpose is simply to provide an up-to-date Git binary. Opting out via
NO_RUSTkeeps builds fast and lean while remaining fully supported by upstream for the 2.x series. This mirrors how several distro package recipes are handling the transition.Follow-up / future work
NO_RUSTis a temporary opt-out and is slated for removal in Git 3.0. Before Git 3.0 lands, this feature will need a follow-up to provision a Rust toolchain (or otherwise satisfy the Rust build requirement) so source builds continue to succeed. Tracking this as a known future task.Testing
>= 2.55.0) from source on Debian/Ubuntugit versionreports the expected>= 2.55.0version after install