Skip to content

Commit b0b055e

Browse files
authored
Merge pull request #106 from infosiftr/BASHBREW_LIBRARY
Fix behavior around `BASHBREW_LIBRARY` in GHA
2 parents 7afe152 + d64a9e8 commit b0b055e

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

scripts/github-actions/generate.sh

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,10 +21,11 @@ if ! command -v bashbrew &> /dev/null; then
2121
bashbrew --version > /dev/null
2222
fi
2323

24-
mkdir "$tmp/library"
25-
export BASHBREW_LIBRARY="$tmp/library"
24+
mkdir "$tmp/library" # not exporting this as BASHBREW_LIBRARY yet so that "generate-stackbrew-library.sh" gets the externally-set value of BASHBREW_LIBRARY (or unset value) so it can use that to change behavior (see https://github.com/docker-library/buildpack-deps/commit/cc2dc88e04e82cb4c4c2091205d888a5d5b386f3 for an example)
25+
26+
eval "${GENERATE_STACKBREW_LIBRARY:-./generate-stackbrew-library.sh}" > "$tmp/library/$image"
2627

27-
eval "${GENERATE_STACKBREW_LIBRARY:-./generate-stackbrew-library.sh}" > "$BASHBREW_LIBRARY/$image"
28+
export BASHBREW_LIBRARY="$tmp/library"
2829

2930
# if we don't appear to be able to fetch the listed commits, they might live in a PR branch, so we should force them into the Bashbrew cache directly to allow it to do what it needs
3031
if ! bashbrew fetch "$image" &> /dev/null; then

0 commit comments

Comments
 (0)