Problem
In hack/release.sh, two shell constructs are left unquoted:
- Line 68:
$(dirname $0) — the inner $0 is not quoted, so the dirname command itself breaks on paths with spaces.
- Line 72:
${REPO_ROOT_DIR} — copied-to destination is unquoted, so word-splitting applies if the path contains spaces.
# line 68 (current)
$(dirname $0)/generate-yamls.sh "${REPO_ROOT_DIR}" "${YAML_LIST}"
# line 72 (current)
cp ${ARTIFACTS_TO_PUBLISH} ${REPO_ROOT_DIR}
Proposed Fix
# line 68
"$(dirname "$0")"/generate-yamls.sh "${REPO_ROOT_DIR}" "${YAML_LIST}"
# line 72
cp ${ARTIFACTS_TO_PUBLISH} "${REPO_ROOT_DIR}"
Problem
In
hack/release.sh, two shell constructs are left unquoted:$(dirname $0)— the inner$0is not quoted, so the dirname command itself breaks on paths with spaces.${REPO_ROOT_DIR}— copied-to destination is unquoted, so word-splitting applies if the path contains spaces.Proposed Fix