Gentoo Archives: gentoo-dev

From: Thomas Deutschmann <whissi@g.o>
To: gentoo-dev@l.g.o
Subject: Re: [gentoo-dev] [PATCH 1/2] acct-user.eclass: Support ACCT_USER_ID override
Date: Wed, 06 Jan 2021 19:31:54
Message-Id: 781cd9aa-a101-90ba-ea98-efbc315b02ad@gentoo.org
In Reply to: Re: [gentoo-dev] [PATCH 1/2] acct-user.eclass: Support ACCT_USER_ID override by Alec Warner
1 On 2021-01-06 20:12, Alec Warner wrote:
2 > Not sure I follow. Whether your automation sets a variable in
3 > /etc/portage/make.conf or /etc/portage/package.env; it's basically the
4 > same problem space; no?
5
6 No.
7
8 Assuming we will always stick to same variables,
9
10 ACCT_USER_ID
11 ACCT_USER_GROUPS
12 ACCT_USER_SHELL
13 ACCT_USER_HOME
14 ACCT_USER_NAME
15 ...
16
17 You don't have to deal with variable names which could clash with other
18 stuff. Instead you will only use values which are safe (no need to care
19 about stuff like underscores)...
20
21 Also, because we are always using same variable names, this will add
22 some kind of consistency and makes documentation easier. Like you can
23 referrer to same example (template) and just need to adjust values (it's
24 actually really hard to get people understand that the example for let's
25 say mail-filter/opendkim requires more than just copying and adjusting
26 *values*; for instance, we have packages named acct-user/foo but
27 *username* is actually food -- do they actually need to override via
28 ACCT_USER_<ACCT-USER-PKGNAME-THEY-WANT-TO-OVERRIDE>_ or
29 ACCT_USER_<NAME-USED-IN-ACCT-USER-PKG-THEY-WANT-TO-OVERRIDE>_? Sticking
30 to same variables names will avoid this confusion).
31
32 Like said we will probably need to introduce an own namespace to
33 override via environment variable and be able to detect the override to
34 have them logged.
35
36
37 --
38 Regards,
39 Thomas Deutschmann / Gentoo Linux Developer
40 fpr: C4DD 695F A713 8F24 2AA1 5638 5849 7EE5 1D5D 74A5