From b2e432c02468b7dd1a6351d0e9f125fad75e5234 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fabiano=20Fid=C3=AAncio?= Date: Wed, 27 Sep 2023 14:19:24 +0200 Subject: [PATCH] packaging: Use git abbreviated hash MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This will make it easier to build images that rely on several directories hashes. Signed-off-by: Fabiano FidĂȘncio (cherry picked from commit 98097c96deae92000997e24f90318ec9536a7fdc) --- tools/packaging/scripts/lib.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/packaging/scripts/lib.sh b/tools/packaging/scripts/lib.sh index e7a6fc987d..8b7b13da10 100644 --- a/tools/packaging/scripts/lib.sh +++ b/tools/packaging/scripts/lib.sh @@ -123,7 +123,7 @@ get_last_modification() { dirty="" [ $(git status --porcelain | grep "${file#${repo_root_dir}/}" | wc -l) -gt 0 ] && dirty="-dirty" - echo "$(git log -1 --pretty=format:"%H" ${file})${dirty}" + echo "$(git log -1 --pretty=format:"%h" ${file})${dirty}" popd &> /dev/null }