summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2008-03-28 10:18:08 +0000
committerZac Medico <zmedico@gentoo.org>2008-03-28 10:18:08 +0000
commitd440bb602d65acb33f72a534f90d331e763e7a6d (patch)
tree8dcad1c5b4afa26f3ab846038724394a3c9f34b6
parentbdaf5371a5710d64594f76f1d3748efdbe913c9e (diff)
downloadportage-d440bb602d65acb33f72a534f90d331e763e7a6d.tar.gz
portage-d440bb602d65acb33f72a534f90d331e763e7a6d.tar.bz2
portage-d440bb602d65acb33f72a534f90d331e763e7a6d.zip
* Skip the recusive chown call if it fails on the top level directory since
it's possible that emerge-webrsync is not run by root. * Just chown to portage:portage instead of using PORTAGE_INST_{UID,GID}. svn path=/main/trunk/; revision=9538
-rwxr-xr-xbin/emerge-webrsync6
1 files changed, 3 insertions, 3 deletions
diff --git a/bin/emerge-webrsync b/bin/emerge-webrsync
index 3a58b2b16..0dd791f3a 100755
--- a/bin/emerge-webrsync
+++ b/bin/emerge-webrsync
@@ -33,7 +33,7 @@ if ! type portageq > /dev/null ; then
exit 1
fi
eval $(portageq envvar -v FEATURES FETCHCOMMAND GENTOO_MIRRORS \
- PORTAGE_BIN_PATH PORTAGE_GPG_DIR PORTAGE_INST_UID PORTAGE_INST_GID \
+ PORTAGE_BIN_PATH PORTAGE_GPG_DIR \
PORTAGE_NICENESS PORTAGE_RSYNC_EXTRA_OPTS PORTAGE_TMPDIR PORTDIR \
http_proxy ftp_proxy)
DISTDIR="${PORTAGE_TMPDIR}/emerge-webrsync"
@@ -189,8 +189,8 @@ sync_local() {
# Free disk space
rm -f "${file}"
- # Make sure user and group file ownership is ${PORTAGE_INST_UID}:${PORTAGE_INST_GID}
- chown -R ${PORTAGE_INST_UID:-0}:${PORTAGE_INST_GID:-0} portage
+ chown portage:portage portage &> /dev/null && \
+ chown -R portage:portage portage
cd portage
rsync -av --progress --stats --delete --delete-after \
--exclude='/distfiles' --exclude='/packages' \