Skip to content

Commit

Permalink
Correct version auto-update
Browse files Browse the repository at this point in the history
  • Loading branch information
mirromutth committed Feb 27, 2024
1 parent 24f188f commit 545b840
Show file tree
Hide file tree
Showing 3 changed files with 32 additions and 2 deletions.
23 changes: 23 additions & 0 deletions .github/scripts/upgrade_native_image_version.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
#!/bin/bash
#
# Copyright 2024 asyncer.io projects
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
set -e

VERSION=$(grep 'project.dev.io.asyncer\\:r2dbc-mysql=' r2dbc-mysql/release.properties | cut -d'=' -f2)

echo 'Set test-native-image version to' $VERSION
./mvnw -pl test-native-image versions:set -DnewVersion=$VERSION
git add test-native-image/pom.xml
9 changes: 8 additions & 1 deletion .github/workflows/cd-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,9 +47,16 @@ jobs:
key: ${{ runner.os }}-prepare-${{ hashFiles('**/pom.xml') }}
restore-keys: ${{ runner.os }}-prepare-

- name: DryRun Release Prepare
run: |
./mvnw -B -ntp -pl r2dbc-mysql release:prepare -DpreparationGoals=clean -DdryRun=true -DskipTests=true
- name: Upgrade Native Image Version
run: ./.github/scripts/upgrade_native_image_version.sh

- name: Run release prepare command
run: |
./mvnw -B -ntp -pl r2dbc-mysql release:prepare -DpreparationGoals=clean -DskipTests=true
./mvnw -B -ntp -pl r2dbc-mysql release:prepare -DpreparationGoals=clean -Dresume=false -DskipTests=true
./mvnw -B -ntp clean
- name: Ensure Prepared
Expand Down
2 changes: 1 addition & 1 deletion test-native-image/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<modelVersion>4.0.0</modelVersion>
<groupId>io.asyncer</groupId>
<artifactId>test-native-image</artifactId>
<version>1.1.2-SNAPSHOT</version>
<version>1.1.3-SNAPSHOT</version>

<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
Expand Down

0 comments on commit 545b840

Please sign in to comment.