diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml new file mode 100644 index 0000000..51e7776 --- /dev/null +++ b/.github/workflows/release.yml @@ -0,0 +1,33 @@ +name: Maven Package and Release osci-render + +on: + push: + branches: [ release ] + +jobs: + build: + + runs-on: windows-latest + + steps: + - uses: actions/checkout@v2 + - name: Set up JDK 15 + uses: actions/setup-java@v2 + with: + java-version: '15' + distribution: 'adopt' + - name: Build with Maven + run: | + mvn -B package + $version= mvn help:evaluate -Dexpression="project.version" -q -DforceStdout + echo "VERSION=$version" >> $env:GITHUB_ENV + echo "Release version $version" > ${{ github.workflow }}-CHANGELOG.txt + - name: Release + uses: softprops/action-gh-release@v1 + with: + body_path: ${{ github.workflow }}-CHANGELOG.txt + tag_name: v${{ env.VERSION }} + files: target/osci-render-${{ env.VERSION }}.exe + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + GITHUB_REPOSITORY: jameshball/osci-render