Skip to content

Commit 4e515b4

Browse files
authored
fix: v1-release-process-to-test (#705)
1 parent 0116968 commit 4e515b4

File tree

2 files changed

+27
-10
lines changed

2 files changed

+27
-10
lines changed

.github/workflows/pr.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ concurrency:
88
cancel-in-progress: true
99
on:
1010
pull_request:
11-
branches: [ master, v2 ]
11+
branches: [ master, v1 ]
1212
workflow_dispatch:
1313
jobs:
1414
build:

.github/workflows/release.yml

Lines changed: 26 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,11 @@ jobs:
99
runs-on: ubuntu-latest
1010
steps:
1111
- uses: actions/checkout@v2
12+
if: ${{ startsWith(github.event.release.tag_name, 'v1.' ) }}
13+
with:
14+
ref: "v1"
15+
- uses: actions/checkout@v2
16+
if: ${{ startsWith(github.event.release.tag_name, 'v2.') }}
1217
- name: Set up Java and Maven
1318
uses: actions/setup-java@v2
1419
with:
@@ -20,20 +25,25 @@ jobs:
2025
run: ./mvnw ${MAVEN_ARGS} versions:set -DnewVersion="${RELEASE_VERSION:1}" versions:commit
2126
env:
2227
RELEASE_VERSION: ${{ github.event.release.tag_name }}
23-
- name: Release Maven package
24-
uses: samuelmeuli/action-maven-publish@v1
25-
with:
26-
maven_profiles: "release"
27-
gpg_private_key: ${{ secrets.GPG_PRIVATE_KEY }}
28-
gpg_passphrase: ${{ secrets.GPG_PASSPHRASE }}
29-
nexus_username: ${{ secrets.OSSRH_USERNAME }}
30-
nexus_password: ${{ secrets.OSSRH_TOKEN }}
28+
# - name: Release Maven package
29+
# uses: samuelmeuli/action-maven-publish@v1
30+
# with:
31+
# maven_profiles: "release"
32+
# gpg_private_key: ${{ secrets.GPG_PRIVATE_KEY }}
33+
# gpg_passphrase: ${{ secrets.GPG_PASSPHRASE }}
34+
# nexus_username: ${{ secrets.OSSRH_USERNAME }}
35+
# nexus_password: ${{ secrets.OSSRH_TOKEN }}
3136

3237
# This is separate job because there were issues with git after release step, was not able to commit changes. See history.
3338
update-working-version:
3439
runs-on: ubuntu-latest
3540
steps:
3641
- uses: actions/checkout@v2
42+
if: ${{ startsWith(github.event.release.tag_name, 'v1.' ) }}
43+
with:
44+
ref: "v1"
45+
- uses: actions/checkout@v2
46+
if: ${{ startsWith(github.event.release.tag_name, 'v2.') }}
3747
- name: Set up Java and Maven
3848
uses: actions/setup-java@v2
3949
with:
@@ -49,7 +59,14 @@ jobs:
4959
git commit -m "Set new SNAPSHOT version into pom files." -a
5060
env:
5161
RELEASE_VERSION: ${{ github.event.release.tag_name }}
52-
- name: Push changes
62+
- name: Push changes v1
63+
uses: ad-m/github-push-action@master
64+
if: ${{ startsWith(github.event.release.tag_name, 'v1.' ) }}
65+
with:
66+
github_token: ${{ secrets.GITHUB_TOKEN }}
67+
branch: "v1"
68+
- name: Push changes v2
5369
uses: ad-m/github-push-action@master
70+
if: ${{ startsWith(github.event.release.tag_name, 'v2.' ) }}
5471
with:
5572
github_token: ${{ secrets.GITHUB_TOKEN }}

0 commit comments

Comments
 (0)