Skip to content

Commit

Permalink
emerge-webrsync: Change repo folder ownership if FEATURES=usersync
Browse files Browse the repository at this point in the history
Bug: https://bugs.gentoo.org/707980
Signed-off-by: David Sardari <[email protected]>
Closes: #1390
Signed-off-by: Sam James <[email protected]>
  • Loading branch information
duxsco authored and thesamesam committed Jan 21, 2025
1 parent 04c5358 commit 2ccc673
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion bin/emerge-webrsync
Original file line number Diff line number Diff line change
Expand Up @@ -697,7 +697,14 @@ main() {

handle_pgp_setup

[[ -d ${repo_location} ]] || mkdir -p "${repo_location}"
if [[ ! -d ${repo_location} ]]; then
mkdir -p "${repo_location}" || die

if has usersync ${FEATURES} ; then
chown "${PORTAGE_USERNAME}":"${PORTAGE_GRPNAME}" "${repo_location}" || die
fi
fi

if [[ ! -w ${repo_location} ]] ; then
die "Repository '${repo_name}' is not writable: ${repo_location}"
fi
Expand Down

0 comments on commit 2ccc673

Please sign in to comment.