We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 2126a09 commit e59ca0eCopy full SHA for e59ca0e
1 file changed
scripts/rc.sh
@@ -10,8 +10,10 @@ if [ -z "$PACKAGE_JSON" ]; then
10
fi
11
12
VERSION=$(jq -r .version "$PACKAGE_JSON")
13
+PACKAGE_NAME=$(jq -r .name "$PACKAGE_JSON")
14
+BASE_VERSION=$(echo "$VERSION" | grep -o "^[0-9]\+\.[0-9]\+\.[0-9]\+")
15
-RC_VERSION=$(npm view @eduzz/ui-layout versions --json | jq -r '.[]' | grep "4.3.0-rc" | sort -V | tail -1 | awk -F'-rc.' '{print $1"-rc."($2+1)}')
16
+RC_VERSION=$(npm view "$PACKAGE_NAME" versions --json | jq -r '.[]' | grep "${BASE_VERSION}-rc" | sort -V | tail -1 | awk -F'-rc.' '{print $1"-rc."($2+1)}')
17
18
if [ -z "$RC_VERSION" ]; then
19
RC_VERSION="${VERSION}-rc.0"
0 commit comments