Update the open source release script

Summary: We no longer require to host the pods on our repository, thus I updated the release script to get rid off the copying part.

Reviewed By: passy

Differential Revision: D15166526

fbshipit-source-id: 1989eff335f83c191b16a78d9562470d7819bc17
This commit is contained in:
Pritesh Nandgaonkar
2019-05-02 04:52:19 -07:00
committed by Facebook Github Bot
parent 1d7b526add
commit 31542ca790

View File

@@ -39,8 +39,8 @@ echo "✨ Making a new release..."
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
SONAR_DIR="$DIR/../" SONAR_DIR="$DIR/../"
FLIPPERKIT_PODSPEC_PATH="$SONAR_DIR/iOS/FlipperKit.podspec" FLIPPERKIT_PODSPEC_PATH="$SONAR_DIR/FlipperKit.podspec"
FLIPPER_PODSPEC_PATH="$SONAR_DIR/xplat/Flipper/Flipper.podspec" FLIPPER_PODSPEC_PATH="$SONAR_DIR/Flipper.podspec"
SONAR_GETTING_STARTED_DOC="$SONAR_DIR/docs/getting-started.md" SONAR_GETTING_STARTED_DOC="$SONAR_DIR/docs/getting-started.md"
SPECS_DIR="$SONAR_DIR/Specs/" SPECS_DIR="$SONAR_DIR/Specs/"
FLIPPERKIT_VERSION_TAG='flipperkit_version' FLIPPERKIT_VERSION_TAG='flipperkit_version'
@@ -71,24 +71,6 @@ else
echo "Updating $SONAR_GETTING_STARTED_DOC" echo "Updating $SONAR_GETTING_STARTED_DOC"
sed -i "s/${FLIPPERKIT_VERSION_TAG} = ${OLD_VERSION}/${FLIPPERKIT_VERSION_TAG} = '${VERSION}'/" "$SONAR_GETTING_STARTED_DOC" sed -i "s/${FLIPPERKIT_VERSION_TAG} = ${OLD_VERSION}/${FLIPPERKIT_VERSION_TAG} = '${VERSION}'/" "$SONAR_GETTING_STARTED_DOC"
fi fi
# Copy Podfiles
if [ ! -d "$SPECS_DIR/FlipperKit/" ] # for file "if [-f /home/rama/file]"
then
mkdir "$SPECS_DIR/FlipperKit/"
fi
if [ ! -d "$SPECS_DIR/Flipper/" ] # for file "if [-f /home/rama/file]"
then
mkdir "$SPECS_DIR/Flipper/"
fi
mkdir "$SPECS_DIR/FlipperKit/$VERSION" # New Specs dir for FlipperKit podspec
mkdir "$SPECS_DIR/Flipper/$VERSION" # New Specs dir for Flipper podspec
echo "Copying FlipperKit.podspec in Specs folder"
cp "$FLIPPERKIT_PODSPEC_PATH" "$SPECS_DIR/FlipperKit/$VERSION" # Copied FlipperKit podspec
echo "Copying Flipper.podspec in Specs folder"
cp "$FLIPPER_PODSPEC_PATH" "$SPECS_DIR/Flipper/$VERSION" # Copied Flipper podspec
echo "Bumping version number for android related files..." echo "Bumping version number for android related files..."
# Update Android related files # Update Android related files
@@ -110,5 +92,9 @@ echo "Release commit made as $RELEASE_REV, creating new snapshot version $SNAPSH
hg commit -m "Flipper Bump: v$SNAPSHOT_VERSION" hg commit -m "Flipper Bump: v$SNAPSHOT_VERSION"
echo "Sumitting diffs for review..." echo "Submitting diffs for review..."
jf submit -n -r.^::. jf submit -n -r.^::.
echo "Once the tag is released on the Github, publish the pods to cocoapods, by running the following commands:"
echo "pod trunk push ~/fbsource/xplat/sonar/Flipper.podspec --use-libraries --allow-warnings --verbose"
echo "pod trunk push ~/fbsource/xplat/sonar/Flipper.podspec --use-libraries --allow-warnings --verbose --skip-import-validation --swift-version=4.0"