[Build] CI job to update natives
This commit is contained in:
1 parent
3d212c75b3
commit
de4012c5b4
1 file changed
+27
-13
@@ -1,5 +1,13 @@
|
|||||||
name: CI Build
|
name: CI Build
|
||||||
on: [ push, pull_request ]
|
on:
|
||||||
|
push:
|
||||||
|
pull_request:
|
||||||
|
workflow_dispatch:
|
||||||
|
inputs:
|
||||||
|
type:
|
||||||
|
description: 'Type'
|
||||||
|
required: true
|
||||||
|
default: 'update'
|
||||||
jobs:
|
jobs:
|
||||||
build-java:
|
build-java:
|
||||||
strategy:
|
strategy:
|
||||||
@@ -8,7 +16,7 @@ jobs:
|
|||||||
name: Build Java
|
name: Build Java
|
||||||
runs-on: ${{ matrix.os }}
|
runs-on: ${{ matrix.os }}
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout repository
|
- name: Checkout Repository
|
||||||
uses: actions/checkout@v2
|
uses: actions/checkout@v2
|
||||||
|
|
||||||
- name: Set up Java 8
|
- name: Set up Java 8
|
||||||
@@ -31,16 +39,10 @@ jobs:
|
|||||||
include:
|
include:
|
||||||
- type: win
|
- type: win
|
||||||
expected: /tmp/imgui/libsNative/windows64/imgui-java64.dll
|
expected: /tmp/imgui/libsNative/windows64/imgui-java64.dll
|
||||||
libName: imgui-java64.dll
|
|
||||||
libNameFt: imgui-java64-ft.dll
|
|
||||||
- type: linux
|
- type: linux
|
||||||
expected: /tmp/imgui/libsNative/linux64/libimgui-java64.so
|
expected: /tmp/imgui/libsNative/linux64/libimgui-java64.so
|
||||||
libName: libimgui-java64.so
|
|
||||||
libNameFt: libimgui-java64-ft.so
|
|
||||||
- type: mac
|
- type: mac
|
||||||
expected: /tmp/imgui/libsNative/macosx64/libimgui-java64.dylib
|
expected: /tmp/imgui/libsNative/macosx64/libimgui-java64.dylib
|
||||||
libName: libimgui-java64.dylib
|
|
||||||
libNameFt: libimgui-java64-ft.dylib
|
|
||||||
exclude:
|
exclude:
|
||||||
- os: ubuntu-20.04
|
- os: ubuntu-20.04
|
||||||
type: mac
|
type: mac
|
||||||
@@ -51,7 +53,7 @@ jobs:
|
|||||||
name: Build Native (type=${{ matrix.type }}, freetype=${{ matrix.freetype }})
|
name: Build Native (type=${{ matrix.type }}, freetype=${{ matrix.freetype }})
|
||||||
runs-on: ${{ matrix.os }}
|
runs-on: ${{ matrix.os }}
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout repository and submodules
|
- name: Checkout Repository and Submodules
|
||||||
uses: actions/checkout@v2
|
uses: actions/checkout@v2
|
||||||
with:
|
with:
|
||||||
submodules: recursive
|
submodules: recursive
|
||||||
@@ -95,10 +97,11 @@ jobs:
|
|||||||
- name: Upload Native
|
- name: Upload Native
|
||||||
uses: actions/upload-artifact@v2
|
uses: actions/upload-artifact@v2
|
||||||
with:
|
with:
|
||||||
name: ${{ matrix.freetype && matrix.libNameFt || matrix.libName }}
|
name: ${{ matrix.freetype && 'freetype' || 'common' }}
|
||||||
path: ${{ matrix.expected }}
|
path: ${{ matrix.expected }}
|
||||||
if-no-files-found: error
|
if-no-files-found: error
|
||||||
update-natives:
|
update-natives:
|
||||||
|
if: github.event.inputs.type == 'update'
|
||||||
name: Update Natives
|
name: Update Natives
|
||||||
runs-on: ubuntu-20.04
|
runs-on: ubuntu-20.04
|
||||||
needs: build-natives
|
needs: build-natives
|
||||||
@@ -108,6 +111,17 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
path: /tmp/artifacts
|
path: /tmp/artifacts
|
||||||
|
|
||||||
- name: Display Natives
|
- name: Checkout Repository
|
||||||
run: ls -al
|
uses: actions/checkout@v2
|
||||||
working-directory: /tmp/artifacts
|
with:
|
||||||
|
token: ${{ secrets.GH_ACTIONS_REPO }}
|
||||||
|
|
||||||
|
- name: Move Natives
|
||||||
|
run: |
|
||||||
|
mv /tmp/artifacts/common/* bin/
|
||||||
|
mv /tmp/artifacts/freetype/* bin/freetype/
|
||||||
|
|
||||||
|
- uses: EndBug/add-and-commit@v7
|
||||||
|
with:
|
||||||
|
message: '[skip ci] Update native binaries'
|
||||||
|
default_author: github_actions
|
||||||
Reference in new issue
Block a user