Skip to content

Commit 675479a

Browse files
committed
Handle sed for semver when no prefixes are provided
1 parent a970082 commit 675479a

1 file changed

Lines changed: 6 additions & 1 deletion

File tree

entrypoint.sh

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -166,7 +166,12 @@ declare -A history_type=(
166166
log=${history_type[${branch_history}]}
167167
printf "History:\n---\n%s\n---\n" "$log"
168168

169-
current_tag="$(echo ${tag}| sed "s/${tagPrefix}//g")"
169+
if [ -z "$tagPrefix" ]
170+
then
171+
current_tag=${tag}
172+
else
173+
current_tag="$(echo ${tag}| sed "s/${tagPrefix}//g")"
174+
fi
170175
case "$log" in
171176
*$major_string_token* ) new=${tagPrefix}$(semver -i major "${current_tag}"); part="major";;
172177
*$minor_string_token* ) new=${tagPrefix}$(semver -i minor "${current_tag}"); part="minor";;

0 commit comments

Comments
 (0)