@@ -50,9 +50,11 @@ SRC_TGZ_FILE="AppleSimulatorUtils-${VERSION}.tar.gz"
5050mkdir -p build
5151tar --exclude=" releaseVersion.sh" --exclude=" .git" --exclude=" build" --exclude=" bottle" --exclude " _tmp_release_notes.md" --exclude=" .github" --exclude=" homebrew-brew" -cvzf " build/${SRC_TGZ_FILE} " .
5252
53- echo -e " \033[1;34mCreating a homebrew bottle "
53+ echo -e " \033[1;34mCreating Homebrew bottles "
5454
5555BOTTLE_TGZ_FILE=" applesimutils-${VERSION} .mojave.bottle.tar.gz"
56+ BOTTLE_TGZ_FILE_HSIERRA=" applesimutils-${VERSION} .high_sierra.bottle.tar.gz"
57+ BOTTLE_TGZ_FILE_SIERRA=" applesimutils-${VERSION} .sierra.bottle.tar.gz"
5658
5759rm -fr bottle
5860BOTTLE_DIR=" bottle/applesimutils/${VERSION} /"
@@ -61,6 +63,9 @@ mkdir -p "${BOTTLE_DIR}"
6163pushd .
6264cd bottle
6365tar -cvzf " ${BOTTLE_TGZ_FILE} " applesimutils
66+
67+ cp " ${BOTTLE_TGZ_FILE} " " ${BOTTLE_TGZ_FILE_HSIERRA} "
68+ cp " ${BOTTLE_TGZ_FILE} " " ${BOTTLE_TGZ_FILE_SIERRA} "
6469popd
6570
6671echo -e " \033[1;34mUpdating brew repository with latest tarball and update applesimutils.rb\033[0m"
@@ -72,8 +77,10 @@ git fetch
7277git pull --rebase
7378sed -i ' ' -e ' s/^\ \ url .*/\ \ url ' " 'https:\/\/github.com\/wix\/AppleSimulatorUtils\/releases\/download\/${VERSION} \/${SRC_TGZ_FILE} '" ' /g' applesimutils.rb
7479sed -i ' ' -e ' s/^\ \ \ \ root\_url .*/\ \ \ \ root\_url ' " 'https:\/\/github.com\/wix\/AppleSimulatorUtils\/releases\/download\/${VERSION} '" ' /g' applesimutils.rb
75- sed -i ' ' -e ' s/^\ \ sha256 .*/\ \ sha256 ' " '" $( shasum -b -a 256 ../build/${SRC_TGZ_FILE} | awk ' { print ${VERSION} }' ) " '" ' /g' applesimutils.rb
76- sed -i ' ' -e ' s/^\ \ \ \ sha256 .*/\ \ \ \ sha256 ' " '" $( shasum -b -a 256 ../bottle/${BOTTLE_TGZ_FILE} | awk ' { print ${VERSION} }' ) " '" ' \ \=\>\ \:mojave/g' applesimutils.rb
80+ sed -i ' ' -e ' s/^\ \ sha256 .*/\ \ sha256 ' " '" $( shasum -b -a 256 ../build/${SRC_TGZ_FILE} | awk ' { print $1 }' ) " '" ' /g' applesimutils.rb
81+ sed -i ' ' -e ' s/^ sha256 .* => :mojave/ sha256 ' " '" $( shasum -b -a 256 ../bottle/${BOTTLE_TGZ_FILE} | awk ' { print $1 }' ) " '" ' => :mojave/g' applesimutils.rb
82+ sed -i ' ' -e ' s/^ sha256 .* => :high_sierra/ sha256 ' " '" $( shasum -b -a 256 ../bottle/${BOTTLE_TGZ_FILE} | awk ' { print $1 }' ) " '" ' => :high_sierra/g' applesimutils.rb
83+ sed -i ' ' -e ' s/^ sha256 .* => :sierra/ sha256 ' " '" $( shasum -b -a 256 ../bottle/${BOTTLE_TGZ_FILE} | awk ' { print $1 }' ) " '" ' => :sierra/g' applesimutils.rb
7784git add -A
7885git commit -m " Apple Simulator Utils ${VERSION} "
7986git push
@@ -100,6 +107,8 @@ echo -e "\033[1;34mUploading attachments to release\033[0m"
100107
101108curl -s --data-binary @" build/${SRC_TGZ_FILE} " -H " Content-Type: application/octet-stream" " https://uploads.github.com/repos/wix/AppleSimulatorUtils/releases/${RELEASE_ID} /assets?name=$( basename ${SRC_TGZ_FILE} ) &access_token=${GITHUB_RELEASES_TOKEN} " | jq " ."
102109curl -s --data-binary @" bottle/${BOTTLE_TGZ_FILE} " -H " Content-Type: application/octet-stream" " https://uploads.github.com/repos/wix/AppleSimulatorUtils/releases/${RELEASE_ID} /assets?name=$( basename ${BOTTLE_TGZ_FILE} ) &access_token=${GITHUB_RELEASES_TOKEN} " | jq " ."
110+ curl -s --data-binary @" bottle/${BOTTLE_TGZ_FILE_HSIERRA} " -H " Content-Type: application/octet-stream" " https://uploads.github.com/repos/wix/AppleSimulatorUtils/releases/${RELEASE_ID} /assets?name=$( basename ${BOTTLE_TGZ_FILE_HSIERRA} ) &access_token=${GITHUB_RELEASES_TOKEN} " | jq " ."
111+ curl -s --data-binary @" bottle/${BOTTLE_TGZ_FILE_SIERRA} " -H " Content-Type: application/octet-stream" " https://uploads.github.com/repos/wix/AppleSimulatorUtils/releases/${RELEASE_ID} /assets?name=$( basename ${BOTTLE_TGZ_FILE_SIERRA} ) &access_token=${GITHUB_RELEASES_TOKEN} " | jq " ."
103112
104113rm -fr build
105114rm -fr bottle
0 commit comments