Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix integer comparison error by ensuring GITHUB_CI_CD is defined #170

Merged
merged 1 commit into from
May 1, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion scripts/env.sh
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,9 @@ rm md5.txt
tar xvjf "${TARBALL}"
rm "${TARBALL}"

# Ensure GITHUB_CI_CD is set and is an integer, default to 0 if not set
GITHUB_CI_CD="${GITHUB_CI_CD:-0}"

if [ -n "${GITHUB_CI_PR_SHA}" ] || [ 1 -eq "${GITHUB_CI_CD}" ]; then
# This is for GitHub Actions CI/CD tooling only
echo "export PATH=\"${CURDIR}/${TARDIR}/bin\":\"\${PATH}\"" > build.env
Expand All @@ -30,4 +33,3 @@ else
echo "to your ~/.profile and/or ~/.bashrc and run the line to enable toolchain as default one for arm-none-eabi-* target"
echo ""
fi;