1 |
commit: 1ebf7392b8c06a505f148de8cbe4ad303ed71275 |
2 |
Author: Mike Frysinger <vapier <AT> gentoo <DOT> org> |
3 |
AuthorDate: Fri Nov 5 09:46:10 2021 +0000 |
4 |
Commit: Mike Frysinger <vapier <AT> gentoo <DOT> org> |
5 |
CommitDate: Fri Nov 5 09:46:10 2021 +0000 |
6 |
URL: https://gitweb.gentoo.org/proj/sandbox.git/commit/?id=1ebf7392 |
7 |
|
8 |
bashrc: setup T & HOME variables |
9 |
|
10 |
Current versions of portage don't write these variables to the env |
11 |
file, so manually set them up ourselves. |
12 |
|
13 |
Signed-off-by: Mike Frysinger <vapier <AT> gentoo.org> |
14 |
|
15 |
data/sandbox.bashrc | 6 +++++- |
16 |
1 file changed, 5 insertions(+), 1 deletion(-) |
17 |
|
18 |
diff --git a/data/sandbox.bashrc b/data/sandbox.bashrc |
19 |
index ec19459..3b953b8 100644 |
20 |
--- a/data/sandbox.bashrc |
21 |
+++ b/data/sandbox.bashrc |
22 |
@@ -79,7 +79,11 @@ if [[ ${SANDBOX_INTRACTV} == "1" && -t 1 ]] || [[ ${__SANDBOX_TESTING} == "yes" |
23 |
-e '/^[[:alnum:]_-]* ()/Q' "${sbs_tmpenvfile}") 2>/dev/null |
24 |
# Then grab everything (including functions) |
25 |
source "${sbs_tmpenvfile}" 2> /dev/null |
26 |
- export SANDBOX_WRITE=${SANDBOX_WRITE}:${sbs_pdir}${sbs_bdir}:${sbs_pdir}/homedir |
27 |
+ # Some variables portage does not write out to th environment. |
28 |
+ : "${T:=${sbs_tmpenvfile%/*}}" |
29 |
+ HOME=${sbs_pdir}/homedir |
30 |
+ SANDBOX_WRITE+=:${sbs_pdir}${sbs_bdir}:${HOME} |
31 |
+ export T HOME SANDBOX_WRITE |
32 |
fi |
33 |
PWD=${sbs_PREPWD} |
34 |
fi |