Action change 6 #13
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: Build Qmod | |
env: | |
module_id: questeditor | |
qmodName: QuestEditor | |
on: | |
workflow_dispatch: | |
push: | |
branches-ignore: | |
- 'version*' | |
pull_request: | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
defaults: | |
run: | |
working-directory: ./qmod | |
steps: | |
- uses: actions/checkout@v2 | |
name: Checkout | |
with: | |
submodules: true | |
lfs: true | |
- uses: friendlyanon/setup-vcpkg@v1 | |
with: { committish: 7f9f0e44db287e8e67c0e888141bfa200ab45121 } | |
- uses: seanmiddleditch/gha-setup-ninja@v3 | |
- name: Create ndkpath.txt | |
run: | | |
echo "$ANDROID_NDK_LATEST_HOME" > ${GITHUB_WORKSPACE}/ndkpath.txt | |
cat ${GITHUB_WORKSPACE}/ndkpath.txt | |
- name: QPM Action | |
uses: Fernthedev/qpm-action@main | |
with: | |
workflow_token: ${{ secrets.GITHUB_TOKEN }} | |
restore: false | |
cache: false | |
publish: false | |
- name: Restore | |
run: | | |
qpm restore | |
- name: List Post Restore | |
run: | | |
echo includes: | |
ls -la ./extern/includes | |
echo libs: | |
ls -la ./extern/libs | |
- name: Create protobuf files | |
run: | | |
cd .. | |
pwsh make-proto.ps1 | |
cd ./qmod | |
ls ./protobuf | |
- name: Build & create qmod | |
run: | | |
qpm s qmod | |
- name: Get Library Name | |
id: libname | |
run: | | |
cd ./build/ | |
pattern="lib${module_id}*.so" | |
files=( $pattern ) | |
echo NAME="${files[0]}" >> $GITHUB_OUTPUT | |
- name: Rename debug | |
run: | | |
mv ./build/debug/${{ steps.libname.outputs.NAME }} ./build/debug/debug_${{ steps.libname.outputs.NAME }} | |
- name: Upload non-debug artifact | |
uses: actions/upload-artifact@v2 | |
with: | |
name: ${{ steps.libname.outputs.NAME }} | |
path: ./build/${{ steps.libname.outputs.NAME }} | |
if-no-files-found: error | |
- name: Upload debug artifact | |
uses: actions/upload-artifact@v2 | |
with: | |
name: debug_${{ steps.libname.outputs.NAME }} | |
path: ./build/debug/debug_${{ steps.libname.outputs.NAME }} | |
if-no-files-found: error | |
- name: Upload qmod artifact | |
uses: actions/upload-artifact@v2 | |
with: | |
name: ${{ env.qmodName }}.qmod | |
path: ./${{ env.qmodName }}.qmod | |
if-no-files-found: error |