Skip to content
Open
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
2 changes: 1 addition & 1 deletion build_openroad.sh
Original file line number Diff line number Diff line change
Expand Up @@ -238,7 +238,7 @@ __docker_build()
sed -i '/flow\/platforms/d' .dockerignore
fi
options=""
if [ -n "${WITH_VERIFIC}" ]; then
if [ ${WITH_VERIFIC} -eq 1 ]; then
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

For improved robustness, it's recommended to use [[...]] for tests, quote variables, and use string comparison for flags. This prevents potential issues like word splitting or errors if the variable is not a valid integer. Using [[...]] is also more consistent with other conditional checks in this script (e.g., on line 194).

Suggested change
if [ ${WITH_VERIFIC} -eq 1 ]; then
if [[ "${WITH_VERIFIC}" == "1" ]]; then

cp -r "${VERIFIC_SRC}" tools/verific
options="-buildArgs=--build-arg verificPath=tools/verific"
fi
Expand Down