Skip to content

0.9.6

0.9.6 #177

name: Build
on:
workflow_dispatch:
release:
types:
- created
jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [macos-latest, ubuntu-latest]
steps:
- name: Checkout repository and submodules
uses: actions/checkout@v3
with:
submodules: recursive
- name: Get Java
uses: actions/setup-java@v3
with:
distribution: 'temurin'
java-version: '17'
- name: Install Lein
uses: knicknic/[email protected]
with:
macos: brew install leiningen
linux: echo "lein is already installed"
- name: Run Tests then Uberjar
run: |
lein run
lein uberjar
- name: Upload Uberjar
uses: shogo82148/actions-upload-release-asset@v1
with:
upload_url: ${{ github.event.release.upload_url }}
asset_path: target/datalevin-${{ github.event.release.tag_name }}-standalone.jar
overwrite: true
- name: Setup Graalvm
uses: DeLaGuardo/setup-graalvm@master
with:
graalvm-version: '22.3.1.java11'
- name: Install Native Image
run: |
gu install native-image
- name: Build Native Datalevin
uses: knicknic/[email protected]
with:
macos: |
cd native
bash script/compile
linux: |
cd native
sudo bash script/setup-musl
bash script/compile-static
- name: Run Native Tests
run: |
native/dtlv-test0
- name: Zip Binary
run: |
cd native
7z a -tzip dtlv-${{ github.event.release.tag_name }}-${{ matrix.os}}-amd64.zip dtlv
- name: Upload Binary
uses: shogo82148/actions-upload-release-asset@v1
with:
upload_url: ${{ github.event.release.upload_url }}
asset_path: native/dtlv-${{ github.event.release.tag_name }}-${{ matrix.os }}-amd64.zip
overwrite: true