Skip to content

Commit

Permalink
Exclude directory structure from binary packages (#467)
Browse files Browse the repository at this point in the history
Previously, it was releasing the folder name in addition to the binary.
This fixes it so it just releases the binary by itself.
  • Loading branch information
mtlynch authored Aug 27, 2023
1 parent 3316d48 commit fce794a
Showing 1 changed file with 9 additions and 3 deletions.
12 changes: 9 additions & 3 deletions dev-scripts/package-binaries
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,14 @@ readonly VERSION
# Exit on unset variable.
set -u

# Change directory to repository root.
SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )"
readonly SCRIPT_DIR
cd "${SCRIPT_DIR}/.."

cd build

readonly OUTPUT_DIR="../dist"
readonly OUTPUT_DIR="${PWD}/../dist"
mkdir -p "${OUTPUT_DIR}"

for d in ./*_*; do
Expand All @@ -34,9 +39,10 @@ for d in ./*_*; do
ARCH="${FOLDER_PARTS[*]}"
ARCH="${ARCH//[[:blank:]]}"

pushd "$d"
tar \
--create \
--verbose \
--file="${OUTPUT_DIR}/picoshare-v${VERSION}-${OS}-${ARCH}.tar.gz" \
"${d}/picoshare"
picoshare
popd
done

0 comments on commit fce794a

Please sign in to comment.