Fix prepare-release.sh script

Summary: Fixed paths after moving js code to "desktop" subfolder

Reviewed By: jknoxville, mweststrate

Differential Revision: D20469775

fbshipit-source-id: 4df963550012905dff4c1ddf6e8b6cd2693b8fbe
This commit is contained in:
Anton Nikolaev
2020-03-16 09:56:30 -07:00
committed by Facebook GitHub Bot
parent 70d417b62b
commit e091c21fba

View File

@@ -42,6 +42,7 @@ echo "✨ Making a new release..."
SANDCASTLE_REVISION="$1" SANDCASTLE_REVISION="$1"
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
SONAR_DIR="$DIR/../" SONAR_DIR="$DIR/../"
DESKTOP_DIR="$SONAR_DIR/desktop"
FLIPPERKIT_PODSPEC_PATH="$SONAR_DIR/FlipperKit.podspec" FLIPPERKIT_PODSPEC_PATH="$SONAR_DIR/FlipperKit.podspec"
FLIPPER_PODSPEC_PATH="$SONAR_DIR/Flipper.podspec" FLIPPER_PODSPEC_PATH="$SONAR_DIR/Flipper.podspec"
TUTORIAL_PODFILE_PATH="$SONAR_DIR/iOS/Tutorial/Podfile" TUTORIAL_PODFILE_PATH="$SONAR_DIR/iOS/Tutorial/Podfile"
@@ -56,8 +57,8 @@ if [ "$SANDCASTLE_REVISION" != "" ];
then then
# In future, bump majors instead of minors? # In future, bump majors instead of minors?
echo "Automatically bumping version to next minor in package.json" echo "Automatically bumping version to next minor in package.json"
npm -C "$SONAR_DIR" version minor npm -C "$DESKTOP_DIR" version minor
VERSION=$(jq -r '.version' "$SONAR_DIR"/package.json) VERSION=$(jq -r '.version' "$DESKTOP_DIR"/package.json)
else else
echo "The currently released version is $OLD_VERSION. What should the version of the next release be?" echo "The currently released version is $OLD_VERSION. What should the version of the next release be?"
read -r VERSION read -r VERSION
@@ -99,7 +100,7 @@ echo "Bumping version number for android related files..."
"$SONAR_DIR"/scripts/bump.sh "$VERSION" "$SONAR_DIR"/scripts/bump.sh "$VERSION"
# Generate changelog # Generate changelog
"$SONAR_DIR"/scripts/generate-changelog.js "$DESKTOP_DIR"/scripts/generate-changelog.js
# Create commit # Create commit
echo "Committing the files..." echo "Committing the files..."