Git fork

ci: fix broken jobs on Ubuntu 25.10 caused by switch to sudo-rs(1)

Ubuntu 25.10 has been released. One prominent change in this version of
Ubuntu is the switch to some Rust-based utilities. Part of this switch
is also that Ubuntu now defaults to sudo-rs(1).

Unfortunately, this breaks our CI because sudo-rs(1) does not support
the `--preserve-env` flag. Let's revert back to the C-based sudo(1)
implementation to fix this.

Signed-off-by: Patrick Steinhardt <ps@pks.im>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

authored by

Patrick Steinhardt and committed by
Junio C Hamano
fddb4842 c44beea4

+9
+9
ci/install-dependencies.sh
··· 61 61 libsecret-1-dev libpcre2-dev meson ninja-build pkg-config \ 62 62 ${CC_PACKAGE:-${CC:-gcc}} $PYTHON_PACKAGE 63 63 64 + # Starting with Ubuntu 25.10, sudo can now be provided via either 65 + # sudo(1) or sudo-rs(1), with the latter being the default. The problem 66 + # is that it does not support `--preserve-env` though, which we rely on 67 + # in our CI. We thus revert back to the C implementation. 68 + if test -f /etc/alternatives/sudo 69 + then 70 + sudo update-alternatives --set sudo /usr/bin/sudo.ws 71 + fi 72 + 64 73 case "$distro" in 65 74 ubuntu-*) 66 75 mkdir --parents "$CUSTOM_PATH"