add package.json to resolve issue with building #32
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
# This is used to build a release for each platform - Windows, Linux, and macOS. | |
# Each platform has multiple installers/packages (e.g. Windows has .exe and .msi). | |
# To Build one gradle is used via the build{OS}{Installer} task. (e.g. buildWindowsExe) | |
name: Build Release | |
on: | |
push: | |
tags: | |
- 'v*.*.*' | |
- 'v*.*.*-pre' | |
permissions: | |
contents: write | |
jobs: | |
BuildRelease: | |
strategy: | |
matrix: | |
TASK: [ buildWindowsExe, buildWindowsMsi, buildLinuxDeb, buildLinuxRpm, buildMacPkg, buildMacDmg ] | |
include: | |
- TASK: buildWindowsExe | |
OS: Windows | |
INSTALLER: Exe | |
RUNTIME: windows-latest | |
- TASK: buildWindowsMsi | |
OS: Windows | |
INSTALLER: Msi | |
RUNTIME: windows-latest | |
- TASK: buildLinuxDeb | |
OS: Linux | |
INSTALLER: Deb | |
RUNTIME: ubuntu-latest | |
- TASK: buildLinuxRpm | |
OS: Linux | |
INSTALLER: Rpm | |
RUNTIME: ubuntu-latest | |
- TASK: buildMacPkg | |
OS: MacOs | |
INSTALLER: Pkg | |
RUNTIME: macos-latest | |
- TASK: buildMacDmg | |
OS: MacOs | |
INSTALLER: Dmg | |
RUNTIME: macos-latest | |
runs-on: ${{ matrix.RUNTIME }} | |
name: Build ${{ matrix.INSTALLER }} for ${{ matrix.OS }} | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Set up JDK 21 | |
uses: actions/setup-java@v3 | |
with: | |
java-version: '21' | |
distribution: 'liberica' | |
cache: gradle | |
- name: Grant execute permission for gradlew | |
run: chmod +x gradlew | |
- name: Build Release | |
run: ./gradlew ${{ matrix.TASK }} --info | |
- name: List files | |
run: ls -R ${{ github.workspace }}/build/installer | |
- name: Upload Release | |
uses: actions/upload-artifact@v3 | |
with: | |
name: ${{ matrix.OS }}-${{ matrix.INSTALLER }} | |
path: ${{ github.workspace }}/build/installer/* | |
if-no-files-found: error | |
retention-days: 14 | |
BuildReleaseJar: | |
name: Build release Jar | |
runs-on: windows-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Set up JDK 21 | |
uses: actions/setup-java@v3 | |
with: | |
java-version: '21' | |
distribution: 'liberica' | |
cache: gradle | |
- name: Grant execute permission for gradlew | |
run: chmod +x gradlew | |
- name: Build Release Jar | |
run: ./gradlew buildReleaseJar | |
- name: List files | |
run: ls -R ${{ github.workspace }}/build/libs | |
- name: Upload Jar | |
uses: actions/upload-artifact@v3 | |
with: | |
name: Jar | |
path: ${{ github.workspace }}/build/libs/* | |
if-no-files-found: error | |
retention-days: 14 | |
PublishRelease: | |
name: Publish Release | |
needs: [ BuildRelease, BuildReleaseJar ] | |
runs-on: ubuntu-latest | |
steps: | |
- name: Download Release Artifacts | |
uses: actions/download-artifact@v3 | |
- name: list artifacts | |
run: ls -R ./ | |
- name: Create Release | |
uses: ncipollo/release-action@v1 | |
with: | |
artifacts: "*/**/*" | |
draft: true # This will make the release a draft, so you can edit it before publishing | |
token: ${{ secrets.GITHUB_TOKEN }} # This is the token to authenticate with GitHub |