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.
2 parents 24a7673 + bab2391 commit 71dc065Copy full SHA for 71dc065
.github/scripts/deploy-userguide
@@ -6,7 +6,26 @@
6
SOURCE=$1
7
TARGET=$2
8
RELEASE=$3
9
-VERSION=`echo "$RELEASE" | cut -c 2-`
+
10
+# Check if RELEASE is empty
11
+if [ -z "$RELEASE" ]; then
12
+ echo "Error: \$RELEASE parameter is empty."
13
+ exit 1
14
+fi
15
16
+VERSION=$(echo "$RELEASE" | cut -c 2-)
17
18
+# Check if VERSION is empty
19
+if [ -z "$VERSION" ]; then
20
+ echo "Error: Failed to extract \$VERSION from \$RELEASE parameter '$RELEASE'."
21
22
23
24
+# Check if VERSION matches the format X.Y.Z
25
+if ! [[ "$VERSION" =~ ^[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
26
+ echo "Error: VERSION '$VERSION' does not match the expected format X.Y.Z."
27
28
29
30
echo "Preparing for version $3"
31
echo "Merging files from $1 to $2"
0 commit comments