From 73fab4020d795c5147c4a7ff24b0382f5a85f32e Mon Sep 17 00:00:00 2001 From: acidicoala <67734819+acidicoala@users.noreply.github.com> Date: Sun, 5 Oct 2025 23:38:23 +0500 Subject: [PATCH] Sync KoalaBox --- .github/workflows/dev-build.yml | 2 +- .github/workflows/kb-build.yml | 79 ------------------- .github/workflows/kb-release.yml | 49 ------------ .../workflows/{build.yml => matrix-build.yml} | 4 +- .github/workflows/tag-release.yml | 7 +- KoalaBox | 2 +- 6 files changed, 7 insertions(+), 136 deletions(-) delete mode 100644 .github/workflows/kb-build.yml delete mode 100644 .github/workflows/kb-release.yml rename .github/workflows/{build.yml => matrix-build.yml} (68%) diff --git a/.github/workflows/dev-build.yml b/.github/workflows/dev-build.yml index 5124f75..2a427d3 100644 --- a/.github/workflows/dev-build.yml +++ b/.github/workflows/dev-build.yml @@ -6,4 +6,4 @@ on: jobs: dev-build: name: '🚧 Development Build' - uses: acidicoala/SmokeAPI/.github/workflows/build.yml@master + uses: acidicoala/SmokeAPI/.github/workflows/matrix-build.yml@master diff --git a/.github/workflows/kb-build.yml b/.github/workflows/kb-build.yml deleted file mode 100644 index 97cbfa9..0000000 --- a/.github/workflows/kb-build.yml +++ /dev/null @@ -1,79 +0,0 @@ -name: Build -on: - workflow_call: - inputs: - module: - description: 'Module to be used in CMake config' - required: true - type: string - - os: - description: '"Windows" or "Linux"' - required: true - type: string - - bitness: - description: '32 or 64' - required: true - type: number - -jobs: - build: - name: 🏗️ Build - runs-on: ${{ inputs.os == 'Linux' && 'ubuntu-24.04' || 'windows-2025'}} - container: ${{ inputs.os == 'Linux' && 'ghcr.io/acidicoala/koalabox:master' || '' }} - env: - BUILD_DIR: ${{ github.workspace }}/build - C_COMPILER: ${{ inputs.os == 'Linux' && 'clang' || 'cl' }} - CXX_COMPILER: ${{ inputs.os == 'Linux' && 'clang++' || 'cl' }} - OUTPUT_PATH: ${{ inputs.os == 'Linux' && '*.so' || 'Release/*.dll' }} - WIN_FLAGS: ${{ inputs.os == 'Windows' && inputs.bitness == 32 && '-A=Win32' || '' }} - LINUX_FLAGS: ${{ inputs.os == 'Linux' && inputs.bitness == 32 && '-DCMAKE_C_FLAGS=-m32 -DCMAKE_CXX_FLAGS=-m32' || '' }} - steps: - # Fix dubious ownership errors in docker container - - name: '✔️ Mark GitHub workspace as safe' - if: ${{ inputs.os == 'Linux' }} - run: git config --global --add safe.directory "$GITHUB_WORKSPACE" - - - name: '🛠️ Check compiler versions' - if: ${{ inputs.os == 'Linux' }} - run: | - clang++ --version - g++ --version - - - name: '📥 Check out repository code' - uses: actions/checkout@v5 - with: - submodules: recursive - - - name: '🗃️ Cache CPM dependencies' - uses: actions/cache@v4 - with: - key: ${{ inputs.os }}-CPM-cache - path: '${{ env.BUILD_DIR }}/.cache' - - - name: '⚙️ Generate build files' - # Note: indenting arguments will lead to parsing errors - run: > - cmake - -B "${{ env.BUILD_DIR }}" - -DMODULE=${{ github.event.inputs.module }} - -DCMAKE_BUILD_TYPE=Release - -DCMAKE_C_COMPILER=${{ env.C_COMPILER }} - -DCMAKE_CXX_COMPILER=${{ env.CXX_COMPILER }} - ${{ env.WIN_FLAGS }} - ${{ env.LINUX_FLAGS }} - --debug-output - - - name: '🏗️ Build ${{ inputs.module }}' - run: > - cmake - --build ${{ env.BUILD_DIR }} - --config Release - --target ${{ inputs.module }} - - - name: '📤 Upload binaries' - uses: actions/upload-artifact@v4 - with: - name: ${{ inputs.module }}-${{ inputs.os }}-${{ inputs.bitness }} - path: ${{ env.BUILD_DIR }}/${{ env.OUTPUT_PATH }} diff --git a/.github/workflows/kb-release.yml b/.github/workflows/kb-release.yml deleted file mode 100644 index 0c7207b..0000000 --- a/.github/workflows/kb-release.yml +++ /dev/null @@ -1,49 +0,0 @@ -name: Create release -on: - workflow_call: - zip_command: - description: 'A shell command for creating a release zip' - required: true - type: string -jobs: - package-project: - name: Package the artifacts into a release zip - if: startsWith(github.ref, 'refs/tags/') - runs-on: ubuntu-latest - permissions: - contents: write - steps: - - name: Setup version tag - run: echo "VERSION_TAG=${GITHUB_REF#refs/tags/}" >> $GITHUB_ENV - - - name: Setup zip name - env: - PROJECT_NAME: ${{ github.event.repository.name }} - run: echo "ZIP_NAME=$PROJECT_NAME-$VERSION_TAG.zip" >> $GITHUB_ENV - - - name: Install required tools - run: | - sudo apt update - sudo apt install zip tree - - - name: Check out repository code - uses: actions/checkout@v5 - with: - submodules: recursive - - - name: Download all workflow run artifacts - uses: actions/download-artifact@v5 - with: - path: artifacts - - - name: Print artifact tree - run: tree artifacts - -# - name: Make release zip -# run: ${{ inputs.zip_command }} - -# - name: 'Test upload' -# uses: actions/upload-artifact@v4 -# with: -# name: release -# path: ${{ env.BUILD_DIR }}/${{ env.OUTPUT_PATH }} diff --git a/.github/workflows/build.yml b/.github/workflows/matrix-build.yml similarity index 68% rename from .github/workflows/build.yml rename to .github/workflows/matrix-build.yml index eae9f2e..344428c 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/matrix-build.yml @@ -5,8 +5,6 @@ on: jobs: build: - name: ${{ matrix.module }}-${{ matrix.os }}-${{ matrix.bitness }} - strategy: fail-fast: false matrix: @@ -14,7 +12,7 @@ jobs: os: [ Linux, Windows ] bitness: [ 32, 64 ] - uses: acidicoala/SmokeAPI/.github/workflows/kb-build.yml@master + uses: acidicoala/KoalaBox/.github/workflows/build-cmake.yml@master with: module: ${{ matrix.module }} os: ${{ matrix.os }} diff --git a/.github/workflows/tag-release.yml b/.github/workflows/tag-release.yml index ba12587..eb3109e 100644 --- a/.github/workflows/tag-release.yml +++ b/.github/workflows/tag-release.yml @@ -8,11 +8,12 @@ on: jobs: build-binaries: name: '🏗️ Build Binaries' - uses: acidicoala/SmokeAPI/.github/workflows/build.yml@master + uses: acidicoala/SmokeAPI/.github/workflows/matrix-build.yml@master create-release: name: '📦 Create Release' - uses: acidicoala/SmokeAPI/.github/workflows/kb-release.yml@master + uses: acidicoala/KoalaBox/.github/workflows/create-release.yml@master needs: build-binaries with: - zip_command: 'TODO' \ No newline at end of file + version: ${{ github.ref_name }} + zip_command: 'TODO' diff --git a/KoalaBox b/KoalaBox index bceac19..cd9b36b 160000 --- a/KoalaBox +++ b/KoalaBox @@ -1 +1 @@ -Subproject commit bceac197236b77eb30f33474c7781f3c8154a123 +Subproject commit cd9b36b82c2ed6cd375b807249681bf3e9479631