commit:     d07b1861d09171dac46f3d770a6c435fe6625f92
Author:     Kerin Millar <kfm <AT> plushkava <DOT> net>
AuthorDate: Sun Jun 22 03:37:32 2025 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Sun Jun 22 10:57:00 2025 +0000
URL:        https://gitweb.gentoo.org/proj/portage.git/commit/?id=d07b1861

emerge-werbsync: rename the digest_content and md5sum_output variables

As concerns the check_file_digest() function, rename the
'digest_content' variable to 'expected_md5', and the 'md5sum_output'
variable to 'md5'.

Signed-off-by: Kerin Millar <kfm <AT> plushkava.net>
Signed-off-by: Sam James <sam <AT> gentoo.org>

 bin/emerge-webrsync | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/bin/emerge-webrsync b/bin/emerge-webrsync
index e75a8d67ca..5dbef3c398 100755
--- a/bin/emerge-webrsync
+++ b/bin/emerge-webrsync
@@ -231,19 +231,19 @@ fetch_file() {
 
 check_file_digest() {
        local digest=$1 file=$2
-       local digest_content md5sum_output
+       local expected_md5 md5
 
        einfo "Checking digest ..."
 
-       if ! read -r digest_content _ < "${digest}"; then
+       if ! read -r expected_md5 _ < "${digest}"; then
                digest=${digest##*/}
                ewarn "Disregarding ${digest@Q} because it couldn't be parsed"
                false
-       elif ! md5sum_output=$(md5sum_hex "${file}"); then
+       elif ! md5=$(md5sum_hex "${file}"); then
                file=${file##*/}
                die "couldn't calculate an MD5 checksum for ${file@Q}"
        else
-               [[ ${md5sum_output} == "${digest_content}" ]]
+               [[ ${md5} == "${expected_md5}" ]]
        fi
 }
 

Reply via email to