Skip to content

Commit

Permalink
[ci][code-gen.yaml] Fix version regex (#1821)
Browse files Browse the repository at this point in the history
The code only matches the 3-segment version, but the native SDK can be
2-segment or 4-segment.
  • Loading branch information
littleGnAl authored Jun 6, 2024
1 parent db692dd commit d7415ab
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tool/terra/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,10 @@ if [ -n "$NEW_VERSION" ]; then
# Check the operating system type
if [[ "$OSTYPE" == "darwin"* ]]; then
# macOS
sed -i '' -E "s/rtc_[0-9]+\.[0-9]+\.[0-9]+/${NEW_VERSION}/g" $TERRA_MAIN_FILE
sed -i '' -E "s/rtc_[0-9]+\.[0-9]+(\.[0-9]+)*/${NEW_VERSION}/g" $TERRA_MAIN_FILE
else
# Linux and other Unix-like systems
sed -i -E "s/rtc_[0-9]+\.[0-9]+\.[0-9]+/${NEW_VERSION}/g" $TERRA_MAIN_FILE
sed -i -E "s/rtc_[0-9]+\.[0-9]+(\.[0-9]+)*/${NEW_VERSION}/g" $TERRA_MAIN_FILE
fi
echo "Updated version to ${NEW_VERSION} in $TERRA_MAIN_FILE"
fi
Expand Down

0 comments on commit d7415ab

Please sign in to comment.