[jhalfs] 03/03: Sudo version check: allows sudo-rs

"Git Owner" ([email protected] via alfs-discuss Mailing List) <[email protected]> Sun, 24 May 2026 14:01:05 +0000
Newsgroups gmane.linux.lfs.automated
Message-ID <[email protected]>
This is a multi-part message in MIME format...

------------=_1779631280-1253-32100
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: 8bit

This is an automated email from the git hooks/post-receive script.

git pushed a commit to branch trunk
in repository jhalfs.

commit 935a076e75118f246615ad1a9b557bd98ad6d5cf
Author: Pierre Labastie <[email protected]>
AuthorDate: Sun May 24 15:58:59 2026 +0200

    Sudo version check: allows sudo-rs
    
    We put 0.2.13 as minimum version, since it is the first to be
    in ubuntu-26.04
---
 common/libs/func_check_version.sh | 9 +++++++--
 1 file changed, 7 insertions(+), 2 deletions(-)

diff --git a/common/libs/func_check_version.sh b/common/libs/func_check_version.sh
index 9e3a816..66a1a47 100644
--- a/common/libs/func_check_version.sh
+++ b/common/libs/func_check_version.sh
@@ -188,8 +188,13 @@ inline_doc
   # Check for minimum sudo version
   SUDO_LOC="$(whereis -b sudo | cut -d" " -f2)"
   if [ -x $SUDO_LOC ]; then
-    sudoVer="$(sudo -V | head -n1 | cut -d" " -f3)"
-    check_version "1.7.0"  "${sudoVer}"      "SUDO"
+    if sudo -V | grep -q sudo-rs; then
+      sudoVer="$(sudo -V | head -n1 | cut -d" " -f2)"
+      check_version "0.2.13"  "${sudoVer}"      "SUDO-RS"
+    else
+      sudoVer="$(sudo -V | head -n1 | cut -d" " -f3)"
+      check_version "1.7.0"  "${sudoVer}"       "SUDO"
+    fi
   else
     echo "${nl_}\"${RED}sudo${OFF}\" ${BOLD}must be installed on your system for jhalfs to run"
     exit 1

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.

------------=_1779631280-1253-32100
Content-Type: text/plain; charset="UTF-8"
Content-Disposition: inline
Content-Transfer-Encoding: 8bit
MIME-Version: 1.0

-- 
http://lists.linuxfromscratch.org/sympa/info/alfs-discuss
Unsubscribe: See the above information page
------------=_1779631280-1253-32100--