summaryrefslogtreecommitdiff
path: root/eclass
diff options
context:
space:
mode:
authorV3n3RiX <venerix@koprulu.sector>2023-11-08 10:24:46 +0000
committerV3n3RiX <venerix@koprulu.sector>2023-11-08 10:24:46 +0000
commit9263a8dda30106335f556e7f5936f5607db6f92c (patch)
tree59614d42ee7ac6187fd0c542956f2aa89c39f6e9 /eclass
parentd8ae0501eb6c157339ede48ca34513d27470e1dc (diff)
gentoo auto-resync : 08:11:2023 - 10:24:46
Diffstat (limited to 'eclass')
-rw-r--r--eclass/Manifest.gzbin38807 -> 38802 bytes
-rw-r--r--eclass/acct-user.eclass16
2 files changed, 16 insertions, 0 deletions
diff --git a/eclass/Manifest.gz b/eclass/Manifest.gz
index 64c39bee24b4..de32d0b045f0 100644
--- a/eclass/Manifest.gz
+++ b/eclass/Manifest.gz
Binary files differ
diff --git a/eclass/acct-user.eclass b/eclass/acct-user.eclass
index f658aa0eabc3..66a4d6667888 100644
--- a/eclass/acct-user.eclass
+++ b/eclass/acct-user.eclass
@@ -431,6 +431,22 @@ acct-user_pkg_postinst() {
opts+=( --prefix "${ROOT}" )
fi
+ local g old_groups del_groups=""
+ old_groups=$(egetgroups "${ACCT_USER_NAME}")
+ for g in ${old_groups//,/ }; do
+ has "${g}" "${groups[@]}" || del_groups+="${del_groups:+, }${g}"
+ done
+ if [[ -n ${del_groups} ]]; then
+ local override_name=${ACCT_USER_NAME^^}
+ override_name=${override_name//-/_}
+ ewarn "Removing user ${ACCT_USER_NAME} from group(s): ${del_groups}"
+ ewarn "To retain the user's group membership in the local system"
+ ewarn "config, override with ACCT_USER_${override_name}_GROUPS or"
+ ewarn "ACCT_USER_${override_name}_GROUPS_ADD in make.conf."
+ ewarn "Documentation reference:"
+ ewarn "https://wiki.gentoo.org/wiki/Practical_guide_to_the_GLEP_81_migration#Override_user_groups"
+ fi
+
elog "Updating user ${ACCT_USER_NAME}"
# usermod outputs a warning if unlocking the account would result in an
# empty password. Hide stderr in a text file and display it if usermod fails.