Release #8
Workflow file for this run
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
name: Release | |
on: | |
release: | |
types: | |
- published | |
jobs: | |
release: | |
runs-on: windows-latest | |
steps: | |
- uses: actions/cache@v3 | |
with: | |
path: | | |
~/.gradle/caches | |
~/.gradle/wrapper | |
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties') }} | |
restore-keys: | | |
${{ runner.os }}-gradle- | |
- name: Check out git repository | |
uses: actions/checkout@v3 | |
- name: Set up JDK 21 | |
uses: actions/setup-java@v3 | |
with: | |
distribution: liberica | |
java-version: 21 | |
- name: Build | |
shell: bash | |
run: | | |
sed -i "s/0\.0\.0/${{ github.event.release.tag_name }}/" gradle.properties | |
sed -i "s/--add-exports=java.desktop\/com.apple.eawt.event=ALL-UNNAMED//" release-bin/.vmoptions | |
mkdir package | |
./gradlew :daw:shadowJar | |
./gradlew --stop | |
cp daw/build/libs/daw.jar package/EchoInMirror.jar | |
cp -R release-bin/. package/ | |
curl https://github.com/EchoInMirror/EIMHost/releases/latest/download/EIMHost-x86.exe -o package/EIMHost-x86.exe -L | |
curl https://github.com/EchoInMirror/EIMHost/releases/latest/download/EIMHost-x64.exe -o package/EIMHost-x64.exe -L | |
env: | |
APP_CENTER_SECRET: ${{ secrets.APP_CENTER_SECRET }} | |
- name: Download ffmpeg | |
shell: bash | |
run: | | |
curl https://github.com/BtbN/FFmpeg-Builds/releases/download/latest/ffmpeg-master-latest-win64-gpl.zip -O -L | |
unzip ffmpeg-master-latest-win64-gpl.zip | |
mkdir package/ffmpeg | |
mv ffmpeg-master-latest-win64-gpl/bin/ffmpeg.exe package/ffmpeg/ffmpeg.exe | |
- name: Download bellsoft jre | |
shell: bash | |
run: | | |
curl https://download.bell-sw.com/java/21.0.1+12/bellsoft-jre21.0.1+12-windows-amd64.zip -O -L | |
unzip -d ./package bellsoft-jre21.0.1+12-windows-amd64.zip | |
mv package/jre-21.0.1 package/jre | |
- name: Package | |
run: | | |
cp LICENSE package/LICENSE | |
mv package EchoInMirror | |
Compress-Archive -Path EchoInMirror -DestinationPath EchoInMirror.zip | |
- name: Upload binaries to release | |
uses: svenstaro/upload-release-action@v2 | |
with: | |
repo_token: ${{ secrets.GITHUB_TOKEN }} | |
file: EchoInMirror.zip | |
asset_name: EchoInMirror-win64.zip | |
tag: ${{ github.ref }} | |
- name: Upload jar to release | |
uses: svenstaro/upload-release-action@v2 | |
with: | |
repo_token: ${{ secrets.GITHUB_TOKEN }} | |
file: EchoInMirror/EchoInMirror.jar | |
asset_name: EchoInMirror-win64.jar | |
tag: ${{ github.ref }} |