Skip to content

Commit

Permalink
Merge pull request #43 from liquibase/fix-mvn-release-push
Browse files Browse the repository at this point in the history
refactor(extension-update-version.yml): change Git user configuration…
  • Loading branch information
jandroav authored Jun 28, 2023
2 parents 9525967 + 1a369ea commit decb2bc
Show file tree
Hide file tree
Showing 4 changed files with 90 additions and 50 deletions.
26 changes: 26 additions & 0 deletions .github/workflows/extension-release-perform.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: Perform release

on:
workflow_call:

jobs:
perform-release:
name: Perform release
runs-on: ubuntu-latest
env:
GITHUB_TOKEN: ${{ secrets.BOT_TOKEN }}
steps:
- name: Configure Git
run: |
git config user.name "liquibot"
git config user.email "[email protected]"
- name: Download release files
id: download-release-files
uses: actions/download-artifact@v3
with:
name: release-files

- name: Perform Maven Release
run: |
mvn -B release:perform -Dusername=liquibot -Dpassword=$GITHUB_TOKEN -Darguments="-Dmaven.javadoc.skip=true -Dmaven.test.skipTests=true -Dmaven.test.skip=true -Dmaven.deploy.skip=true" -DreleaseVersion=${{ github.event.inputs.liquibaseVersion }} -DconnectionUrl=scm:git:https://github.com/${{ github.repository }}.git -Dtag=${{ github.event.inputs.liquibaseVersion }}
38 changes: 38 additions & 0 deletions .github/workflows/extension-release-prepare.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
name: Prepare release

on:
workflow_call:

jobs:
prepare-release:
name: Prepare release
runs-on: ubuntu-latest
env:
GITHUB_TOKEN: ${{ secrets.BOT_TOKEN }}
steps:
- name: Checkout code
uses: actions/checkout@v3

- name: Set up JDK
uses: actions/setup-java@v2
with:
java-version: 17
distribution: 'temurin'
cache: 'maven'

- name: Configure Git
run: |
git config user.name "liquibot"
git config user.email "[email protected]"
- name: Prepare Maven Release
run: |
mvn -B release:clean release:prepare -Dusername=liquibot -Dpassword=$GITHUB_TOKEN -Darguments="-Dmaven.javadoc.skip=true -Dmaven.test.skipTests=true -Dmaven.test.skip=true -Dmaven.deploy.skip=true" -DreleaseVersion=${{ github.event.inputs.liquibaseVersion }}
- name: Save Release files
uses: actions/upload-artifact@v3
with:
name: release-files
path: |
**/pom.xml.*
**/release.properties
26 changes: 26 additions & 0 deletions .github/workflows/extension-release-rollback.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: Release rollback

on:
workflow_call:

jobs:
rollback-release:
name: Release rollback
runs-on: ubuntu-latest
env:
GITHUB_TOKEN: ${{ secrets.BOT_TOKEN }}
steps:
- name: Configure Git
run: |
git config user.name "liquibot"
git config user.email "[email protected]"
- name: Download release files
id: download-release-files
uses: actions/download-artifact@v3
with:
name: release-files

- name: Perform Maven Release Rollback
run: |
mvn -B release:rollback -Dusername=liquibot -Dpassword=$GITHUB_TOKEN -Darguments="-Dmaven.javadoc.skip=true -Dmaven.test.skipTests=true -Dmaven.test.skip=true -Dmaven.deploy.skip=true" -DreleaseVersion=${{ github.event.inputs.liquibaseVersion }} -DconnectionUrl=scm:git:https://github.com/${{ github.repository }}.git -Dtag=${{ github.event.inputs.liquibaseVersion }}
50 changes: 0 additions & 50 deletions .github/workflows/extension-update-version.yml

This file was deleted.

0 comments on commit decb2bc

Please sign in to comment.