File tree Expand file tree Collapse file tree 2 files changed +10
-5
lines changed
Expand file tree Collapse file tree 2 files changed +10
-5
lines changed Original file line number Diff line number Diff line change @@ -3,7 +3,7 @@ package version
33
44// DDLambdaVersion is the current version number of this library (datadog-lambda-go).
55// It is automatically updated by the release script.
6- const DDLambdaVersion = "v1 .27.0"
6+ const DDLambdaVersion = "1 .27.0"
77
88// DDTraceVersion is the version of dd-trace-go required by this libary.
99// This should match the version number specified in go.mod.
Original file line number Diff line number Diff line change 2525if [ -z " $1 " ]; then
2626 echo " Must specify a desired version number"
2727 exit 1
28- elif [[ ! $1 =~ [0-9]+\. [0-9]+\. [0-9]+ ]]; then
29- echo " Must use a semantic version, e.g., 3.1.4"
30- exit 1
3128else
32- NEW_VERSION=$1
29+ # Remove 'v' prefix if present
30+ CLEAN_VERSION=${1# v}
31+
32+ if [[ ! $CLEAN_VERSION =~ ^[0-9]+\. [0-9]+\. [0-9]+$ ]]; then
33+ echo " Must use a semantic version, e.g., 3.1.4"
34+ exit 1
35+ else
36+ NEW_VERSION=$CLEAN_VERSION
37+ fi
3338fi
3439
3540CURRENT_DD_TRACE_VERSION=" $( grep " const DDTraceVersion" internal/version/version.go | grep -o -E " [0-9]+\.[0-9]+\.[0-9]+" ) "
You can’t perform that action at this time.
0 commit comments