Skip to content

Commit

Permalink
Add Setup Java step to Version Bump and Github Release release jobs a…
Browse files Browse the repository at this point in the history
…nd add temp workflow (#1077)
  • Loading branch information
tdchow authored Jul 23, 2024
1 parent e5500e0 commit 96b2588
Show file tree
Hide file tree
Showing 2 changed files with 63 additions and 0 deletions.
4 changes: 4 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -252,6 +252,8 @@ jobs:
steps:
- name: Checkout Repository
uses: actions/checkout@v2
- name: Setup Java
uses: ./.github/actions/setup
- name: Set GitHub User
uses: ./.github/actions/set_github_user
- name: Update Version
Expand All @@ -277,6 +279,8 @@ jobs:
steps:
- name: Checkout Repository
uses: actions/checkout@v2
- name: Setup Java
uses: ./.github/actions/setup
- name: Save changelog entries to a file
run: |
sed -e '1,/##/d' -e '/##/,$d' CHANGELOG.md > changelog_entries.md
Expand Down
59 changes: 59 additions & 0 deletions .github/workflows/temp_release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
name: Temp Release Workflow
on:
workflow_dispatch:
inputs:
version:
description: 'Version to release'
required: true
env:
SIGNING_KEY_FILE_PATH: /home/runner/secretKey.gpg
jobs:
bump_version:
name: Bump Version
runs-on: ubuntu-latest
steps:
- name: Checkout Repository
uses: actions/checkout@v2
- name: Setup Java
uses: ./.github/actions/setup
- name: Set GitHub User
uses: ./.github/actions/set_github_user
- name: Update Version
run: |
./gradlew -PversionParam=${{ github.event.inputs.version }} changeGradleReleaseVersion
./gradlew -PversionParam=${{ github.event.inputs.version }} changeREADMEVersion
./gradlew -PversionParam=${{ github.event.inputs.version }} changeMigrationGuideVersion
./gradlew -PversionParam=${{ github.event.inputs.version }} updateCHANGELOGVersion
./gradlew dokkaHtmlMultiModule
git add -A
git commit -am 'Release ${{ github.event.inputs.version }}'
git tag ${{ github.event.inputs.version }} -a -m 'Release ${{ github.event.inputs.version }}'
./gradlew -PversionParam=${{ github.event.inputs.version }} incrementSNAPSHOTVersion
./gradlew incrementVersionCode
git commit -am 'Prepare for development'
git push origin main ${{ github.event.inputs.version }}
create_github_release:
needs: [ bump_version ]
name: Create GitHub Release
runs-on: ubuntu-latest
steps:
- name: Checkout Repository
uses: actions/checkout@v2
- name: Setup Java
uses: ./.github/actions/setup
- name: Save changelog entries to a file
run: |
sed -e '1,/##/d' -e '/##/,$d' CHANGELOG.md > changelog_entries.md
- name: Create GitHub release
id: create_release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ github.event.inputs.version }}
release_name: ${{ github.event.inputs.version }}
body_path: changelog_entries.md
draft: false
prerelease: false

0 comments on commit 96b2588

Please sign in to comment.