File tree Expand file tree Collapse file tree 3 files changed +11
-2
lines changed
repo2docker/buildpacks/conda
tests/venv/start/postBuild Expand file tree Collapse file tree 3 files changed +11
-2
lines changed Original file line number Diff line number Diff line change 1
1
# enable conda and activate the notebook environment
2
- set -ex
2
+ set -e
3
3
eval $( micromamba shell hook -s posix -r ${CONDA_DIR} )
4
4
for name in conda mamba; do
5
5
CONDA_PROFILE=" ${CONDA_DIR} /etc/profile.d/${name} .sh"
@@ -21,3 +21,5 @@ if [[ "${KERNEL_PYTHON_PREFIX}" != "${NB_PYTHON_PREFIX}" ]]; then
21
21
else
22
22
mamba activate ${NB_PYTHON_PREFIX}
23
23
fi
24
+
25
+ set +e
Original file line number Diff line number Diff line change @@ -3,3 +3,5 @@ postBuild and start
3
3
4
4
This test checks that we can use a postBuild and start script
5
5
at the same time.
6
+
7
+ It also checks that exit on error (set -e) has not leaked into the main shell.
Original file line number Diff line number Diff line change 1
- #! /bin/bash
1
+ #! /bin/bash -il
2
+ # Run this as an interactive login shell so that the conda profile is sourced
3
+
4
+ # Test that `set -e` isn't incorrectly set in a profile
5
+ false
6
+
2
7
set -euo pipefail
3
8
grep ' Done!' $HOME /postbuild.txt
4
9
# set value of TEST_START_VAR to empty string when it is not defined
You can’t perform that action at this time.
0 commit comments