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

package-all.sh: Don't use parameter expansion for paths #20385

Merged
merged 1 commit into from
Dec 31, 2022
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
7 changes: 4 additions & 3 deletions packaging/package-all.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,16 @@
set -o errexit -o pipefail || exit $?

if [ $# -ne "2" ]; then
echo "Usage: ${0##*/} version outputdir."
echo "Usage: $(basename "$0") version outputdir."
exit 1
fi

export GIT_TAG="$1"
export BUILD_OUTPUT_DIR="$2"

# Set the working dir to the location of this script using bash parameter expansion
cd "${0%/*}"
# Set the working dir to the location of this script
HERE=$(dirname "$0")
cd "${HERE}"

#build packages using a subshell so directory changes do not persist beyond the function
function build_package() (
Expand Down