sparrow/.github/workflows/package.yaml

42 lines
1.2 KiB
YAML
Raw Normal View History

2020-08-25 14:10:56 +00:00
name: Package
2020-08-24 13:37:35 +00:00
2020-08-24 13:40:44 +00:00
on: workflow_dispatch
2020-08-24 13:37:35 +00:00
jobs:
build:
2020-08-25 14:20:45 +00:00
runs-on: ${{ matrix.os }}
strategy:
matrix:
2022-06-07 11:59:30 +00:00
os: [windows-latest, ubuntu-latest, macos-latest]
2020-08-24 13:37:35 +00:00
steps:
- uses: actions/checkout@v3
2020-08-24 15:46:28 +00:00
with:
submodules: true
2022-08-02 11:38:45 +00:00
- name: Set up JDK 18.0.1
uses: actions/setup-java@v3
with:
distribution: 'temurin'
2022-08-02 11:38:45 +00:00
java-version: '18.0.1'
2020-08-25 13:31:04 +00:00
- name: Show Build Versions
run: ./gradlew -v
2020-08-24 13:37:35 +00:00
- name: Cache Gradle packages
uses: actions/cache@v3
2020-08-24 13:37:35 +00:00
with:
path: ~/.gradle/caches
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle') }}
restore-keys: ${{ runner.os }}-gradle
- name: Build with Gradle
run: ./gradlew jpackage
- name: Package zip distribution
2022-06-07 13:01:00 +00:00
if: ${{ runner.os == 'Windows' || runner.os == 'macOS' }}
run: ./gradlew packageZipDistribution
- name: Package tar distribution
2022-06-07 13:01:00 +00:00
if: ${{ runner.os == 'Linux' }}
run: ./gradlew packageTarDistribution
2020-08-24 13:37:35 +00:00
- name: Upload Artifacts
uses: actions/upload-artifact@v2
with:
2020-08-25 14:10:56 +00:00
name: Sparrow Build - ${{ runner.os }}
path: |
build/jpackage/*
!build/jpackage/Sparrow/