-
Notifications
You must be signed in to change notification settings - Fork 15
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add release workflow and refactor pre-release
Signed-off-by: Andre Bossert <[email protected]>
- Loading branch information
Showing
4 changed files
with
95 additions
and
15 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
# This workflow will build a Java project with Maven, and cache/restore any dependencies to improve the workflow execution time | ||
# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-maven | ||
|
||
name: Build-Release | ||
|
||
on: | ||
push: | ||
branches: | ||
- 'release*' | ||
|
||
jobs: | ||
|
||
default: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- name: Set up JDK 11 | ||
uses: actions/setup-java@v2 | ||
with: | ||
java-version: '11' | ||
distribution: 'temurin' | ||
cache: maven | ||
- name: Build release for default platform | ||
run: 'mvn -Dsite.dir=release clean verify' | ||
- name: Assign build.version.properties to env variable | ||
run: cat site/target/build.version.properties >> $GITHUB_ENV | ||
- name: Create Pull Request | ||
uses: peter-evans/create-pull-request@v3 | ||
with: | ||
commit-message: '[${{ env.build_version_major_minor }}] release build ${{ env.build_version_full }}' | ||
title: '[${{ env.build_version_major_minor }}] release build ${{ env.build_version_full }}' | ||
body: | | ||
[Milestone ${{ env.build_version_unqualified }}](https://github.com/anb0s/EasyShell/milestone/${{ env.build_version_milestone }}?closed=1) | ||
labels: | | ||
help wanted | ||
Version ${{ env.build_version_unqualified }} | ||
milestone: ${{ env.build_version_milestone }} | ||
delete-branch: true | ||
base: main |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
# This workflow will build a Java project with Maven, and cache/restore any dependencies to improve the workflow execution time | ||
# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-maven | ||
|
||
name: Release | ||
|
||
on: | ||
push: | ||
tags: | ||
- "v[0-9]+.[0-9]+.[0-9]+" | ||
|
||
jobs: | ||
|
||
deploy-release: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- name: Deploy for Release | ||
uses: JamesIves/github-pages-deploy-action@v4 | ||
with: | ||
branch: gh-pages | ||
folder: site/updates | ||
clean: false | ||
- name: Assign build.version.properties to env variable | ||
run: cat site/updates/release/build.version.properties >> $GITHUB_ENV | ||
- name: 'Zip artifacts ${{ env.build_version_full }} for Release' | ||
uses: papeloto/action-zip@v1 | ||
with: | ||
files: site/updates/release/${{ env.build_version_path }} | ||
dest: EasyShell-${{ env.build_version_full }}.zip | ||
- name: Release | ||
uses: softprops/action-gh-release@v1 | ||
with: | ||
generate_release_notes: true | ||
prerelease: false | ||
body: | | ||
### Release build **${{ env.build_version_full }}** | ||
All versions update site: `http://anb0s.github.io/EasyShell` | ||
Exact version update site: `http://anb0s.github.io/EasyShell/release/${{ env.build_version_path }}` | ||
Version: `EasyShell ${{ env.build_version_full }}` | ||
**Use "Help | Install New Software...", paste the update site link and select the right version!** | ||
[Milestone ${{ env.build_version_unqualified }}](https://github.com/anb0s/EasyShell/milestone/${{ env.build_version_milestone }}?closed=1) | ||
files: EasyShell-${{ env.build_version_full }}.zip |