This commit is contained in:
parent
012ab48110
commit
c8167af618
@ -16,10 +16,8 @@ steps:
|
|||||||
commands:
|
commands:
|
||||||
- echo "Checking project version..."
|
- echo "Checking project version..."
|
||||||
- VERSION_CURRENT=$(grep 'version =' main.go | cut -d'"' -f2)
|
- VERSION_CURRENT=$(grep 'version =' main.go | cut -d'"' -f2)
|
||||||
- echo "Project version: $VERSION_CURRENT"
|
|
||||||
- PREV_COMMIT=$(git rev-parse HEAD^)
|
- PREV_COMMIT=$(git rev-parse HEAD^)
|
||||||
- VERSION_PREV=$(git show "$PREV_COMMIT:main.go" | grep 'version =' | cut -d'"' -f2)
|
- VERSION_PREV=$(git show "$PREV_COMMIT:main.go" | grep 'version =' | cut -d'"' -f2)
|
||||||
- echo "Previous version: $VERSION_PREV"
|
|
||||||
- |
|
- |
|
||||||
if [ "$VERSION_CURRENT" = "$VERSION_PREV" ]; then
|
if [ "$VERSION_CURRENT" = "$VERSION_PREV" ]; then
|
||||||
echo "❌ The version has not changed. You must update it to merge to main."
|
echo "❌ The version has not changed. You must update it to merge to main."
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user