packaging: Simplify get_last_modification()

There's no need to pass repo_root_dir to get_last_modification() as the
variable used everywhere is exported from that very same file.

Fixes: #6431

Signed-off-by: Fabiano Fidêncio <fabiano.fidencio@intel.com>
This commit is contained in:
Fabiano Fidêncio
2023-03-08 21:13:34 +01:00
parent 33c5c49719
commit 43ce3f7588
7 changed files with 8 additions and 10 deletions

View File

@@ -102,11 +102,9 @@ get_kata_hash() {
git ls-remote --heads --tags "https://github.com/${project}/${repo}.git" | grep "${ref}" | awk '{print $1}'
}
# $1 - Repo's root dir
# $2 - The file we're looking for the last modification
# $1 - The file we're looking for the last modification
get_last_modification() {
local repo_root_dir="${1}"
local file="${2}"
local file="${1}"
# This is a workaround needed for when running this code on Jenkins
git config --global --add safe.directory ${repo_root_dir} &> /dev/null