Skip to content

Commit

Permalink
packages - fix update check due to security warning with git 2.34.1
Browse files Browse the repository at this point in the history
As with e041a0c we need to use the same user for running git as the owner of the repository files.

This is also needed for an update check in rp_hasNewerModule as we check the last commit date of scriptmodules in RetroPie-Setup.
  • Loading branch information
joolswills committed May 13, 2022
1 parent 5cf9b95 commit 1eedc5a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion scriptmodules/packages.sh
Original file line number Diff line number Diff line change
Expand Up @@ -643,7 +643,7 @@ function rp_hasNewerModule() {
local vendor="${__mod_info[$id/vendor]}"
local repo_dir="$scriptdir"
[[ "$vendor" != "RetroPie" ]] && repo_dir+="/ext/$vendor"
local module_date="$(git -C "$repo_dir" log -1 --format=%cI -- "${__mod_info[$id/path]}")"
local module_date="$(sudo -u "$user" git -C "$repo_dir" log -1 --format=%cI -- "${__mod_info[$id/path]}")"
if rp_dateIsNewer "$pkg_date" "$module_date"; then
ret=0
fi
Expand Down

0 comments on commit 1eedc5a

Please sign in to comment.