From 439b8f9b0c3e95155ad4f36df8936db5d72a44d9 Mon Sep 17 00:00:00 2001 From: tom Date: Fri, 27 Feb 2026 09:30:38 +0000 Subject: [PATCH 01/29] run tests on PR --- .github/workflows/tests.yml | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 .github/workflows/tests.yml diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml new file mode 100644 index 0000000..43edeb8 --- /dev/null +++ b/.github/workflows/tests.yml @@ -0,0 +1,29 @@ +name: CMake on a single platform + +on: + pull_request: + branches: [ "main" ] + +jobs: + build: + # The CMake configure and build commands are platform agnostic and should work equally well on Windows or Mac. + # You can convert this to a matrix build if you need cross-platform coverage. + # See: https://docs.github.com/en/free-pro-team@latest/actions/learn-github-actions/managing-complex-workflows#using-a-build-matrix + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v4 + + - name: Configure CMake + # Configure CMake in a 'build' subdirectory. + run: cmake --preset debug + + - name: Build + # Build your program with the given configuration + run: cmake --build --preset tests-debug + + - name: Test + working-directory: ${{github.workspace}}/build/debug + # Execute tests + run: ./tests + From 1942764f3f7334a314b6c5a4f0acbaffa16be28f Mon Sep 17 00:00:00 2001 From: tom Date: Fri, 27 Feb 2026 09:33:23 +0000 Subject: [PATCH 02/29] install opengl for build --- .github/workflows/tests.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 43edeb8..6512f35 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -14,6 +14,9 @@ jobs: steps: - uses: actions/checkout@v4 + - name: Deps + run: sudo apt-get install libgl1-mesa-dev + - name: Configure CMake # Configure CMake in a 'build' subdirectory. run: cmake --preset debug From 413ef586587adc3cee571e74ae1859add03d8a8a Mon Sep 17 00:00:00 2001 From: tom Date: Fri, 27 Feb 2026 09:35:48 +0000 Subject: [PATCH 03/29] checkout submodules --- .github/workflows/tests.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 6512f35..ad84df7 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -13,10 +13,12 @@ jobs: steps: - uses: actions/checkout@v4 + with: + submodules: recursive - name: Deps run: sudo apt-get install libgl1-mesa-dev - + - name: Configure CMake # Configure CMake in a 'build' subdirectory. run: cmake --preset debug From 63ccb04af993c05749efb58b55c101980567b044 Mon Sep 17 00:00:00 2001 From: tom Date: Fri, 27 Feb 2026 09:50:49 +0000 Subject: [PATCH 04/29] sdl deps and cache --- .github/workflows/tests.yml | 24 ++++++++++++++++++++++-- 1 file changed, 22 insertions(+), 2 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index ad84df7..da9d482 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -5,7 +5,9 @@ on: branches: [ "main" ] jobs: - build: + tests: + + # The CMake configure and build commands are platform agnostic and should work equally well on Windows or Mac. # You can convert this to a matrix build if you need cross-platform coverage. # See: https://docs.github.com/en/free-pro-team@latest/actions/learn-github-actions/managing-complex-workflows#using-a-build-matrix @@ -16,8 +18,26 @@ jobs: with: submodules: recursive + - name: Cache cmake + id: cache-cmake + uses: actions/cache/v4 + with: + path: build/debug + + - if: ${{ steps.cache-npm.outputs.cache-hit != 'true' }} + name: Report on cache + continue-on-error: true + run: echo "cache hit" + - name: Deps - run: sudo apt-get install libgl1-mesa-dev + run: | + sudo apt-get install libgl1-mesa-dev build-essential git make \ + pkg-config cmake ninja-build gnome-desktop-testing libasound2-dev libpulse-dev \ + libaudio-dev libfribidi-dev libjack-dev libsndio-dev libx11-dev libxext-dev \ + libxrandr-dev libxcursor-dev libxfixes-dev libxi-dev libxss-dev libxtst-dev \ + libxkbcommon-dev libdrm-dev libgbm-dev libgl1-mesa-dev libgles2-mesa-dev \ + libegl1-mesa-dev libdbus-1-dev libibus-1.0-dev libudev-dev libthai-dev \ + libpipewire-0.3-dev libwayland-dev libdecor-0-dev liburing-dev - name: Configure CMake # Configure CMake in a 'build' subdirectory. From d43e01be433d0652c2d267ce5528aac31355b3e1 Mon Sep 17 00:00:00 2001 From: tom Date: Fri, 27 Feb 2026 09:51:58 +0000 Subject: [PATCH 05/29] fix yaml --- .github/workflows/tests.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index da9d482..aec81ff 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -22,7 +22,7 @@ jobs: id: cache-cmake uses: actions/cache/v4 with: - path: build/debug + path: build/debug - if: ${{ steps.cache-npm.outputs.cache-hit != 'true' }} name: Report on cache From caba55a0a54664a4d5ee4428c49acfe3e12203c6 Mon Sep 17 00:00:00 2001 From: tom Date: Fri, 27 Feb 2026 09:53:24 +0000 Subject: [PATCH 06/29] fix yaml --- .github/workflows/tests.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index aec81ff..427621d 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -20,7 +20,7 @@ jobs: - name: Cache cmake id: cache-cmake - uses: actions/cache/v4 + uses: actions/cache@v4 with: path: build/debug From 60168b05f7e457333341af72f502d47b7424d0f6 Mon Sep 17 00:00:00 2001 From: tom Date: Fri, 27 Feb 2026 09:56:00 +0000 Subject: [PATCH 07/29] fix yaml --- .github/workflows/tests.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 427621d..01aa1c7 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -23,6 +23,7 @@ jobs: uses: actions/cache@v4 with: path: build/debug + key: cmake-cache - if: ${{ steps.cache-npm.outputs.cache-hit != 'true' }} name: Report on cache From a0bd98458b6a59d6f7e6e5a5677dd6855ccf0704 Mon Sep 17 00:00:00 2001 From: tom Date: Fri, 27 Feb 2026 10:00:10 +0000 Subject: [PATCH 08/29] check cache hitting --- .github/workflows/tests.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 01aa1c7..b020fcb 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -28,7 +28,7 @@ jobs: - if: ${{ steps.cache-npm.outputs.cache-hit != 'true' }} name: Report on cache continue-on-error: true - run: echo "cache hit" + run: echo "cache hit actually" - name: Deps run: | From 7c3730a90a1c390a82216ea5a2dd95da33a64437 Mon Sep 17 00:00:00 2001 From: tom Date: Fri, 27 Feb 2026 10:57:53 +0000 Subject: [PATCH 09/29] use ccache --- .github/workflows/tests.yml | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index b020fcb..d4d48cf 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -18,17 +18,19 @@ jobs: with: submodules: recursive - - name: Cache cmake - id: cache-cmake + - name: Cache ccache + id: cache-ccache uses: actions/cache@v4 with: - path: build/debug - key: cmake-cache + path: $HOME/.cache/ccache + key: cache-cache + restore-keys: | + $HOME/.cache/ccache - - if: ${{ steps.cache-npm.outputs.cache-hit != 'true' }} + - if: ${{ steps.cache-ccache.outputs.cache-hit == 'true' }} name: Report on cache continue-on-error: true - run: echo "cache hit actually" + run: echo "cache hit" - name: Deps run: | @@ -38,11 +40,11 @@ jobs: libxrandr-dev libxcursor-dev libxfixes-dev libxi-dev libxss-dev libxtst-dev \ libxkbcommon-dev libdrm-dev libgbm-dev libgl1-mesa-dev libgles2-mesa-dev \ libegl1-mesa-dev libdbus-1-dev libibus-1.0-dev libudev-dev libthai-dev \ - libpipewire-0.3-dev libwayland-dev libdecor-0-dev liburing-dev + libpipewire-0.3-dev libwayland-dev libdecor-0-dev liburing-dev ccache - name: Configure CMake # Configure CMake in a 'build' subdirectory. - run: cmake --preset debug + run: cmake --preset debug -DCMAKE_C_COMPILER_LAUNCHER=ccache -DCMAKE_CXX_COMPILER_LAUNCHER=ccache - name: Build # Build your program with the given configuration From ed00dfaae411a38cc103e8ab988a810cc6dcc125 Mon Sep 17 00:00:00 2001 From: tom Date: Fri, 27 Feb 2026 11:03:38 +0000 Subject: [PATCH 10/29] fix yaml --- .github/workflows/tests.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index d4d48cf..210234a 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -24,8 +24,8 @@ jobs: with: path: $HOME/.cache/ccache key: cache-cache - restore-keys: | - $HOME/.cache/ccache + restore-keys: | + $HOME/.cache/ccache - if: ${{ steps.cache-ccache.outputs.cache-hit == 'true' }} name: Report on cache From 66ef40eee32b5372056b9b184e41ac5a96b8978a Mon Sep 17 00:00:00 2001 From: tom Date: Fri, 27 Feb 2026 11:10:16 +0000 Subject: [PATCH 11/29] check cache hitting --- .github/workflows/tests.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 210234a..2dd9a18 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -30,7 +30,7 @@ jobs: - if: ${{ steps.cache-ccache.outputs.cache-hit == 'true' }} name: Report on cache continue-on-error: true - run: echo "cache hit" + run: echo "cache hit yes" - name: Deps run: | From 0bc864df9444738271f4e1f3a858f64c3193d0e8 Mon Sep 17 00:00:00 2001 From: tom Date: Fri, 27 Feb 2026 11:13:00 +0000 Subject: [PATCH 12/29] try to hit cache --- .github/workflows/tests.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 2dd9a18..a0b5b5c 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -22,8 +22,8 @@ jobs: id: cache-ccache uses: actions/cache@v4 with: - path: $HOME/.cache/ccache - key: cache-cache + path: $HOME/.cache + key: ccache restore-keys: | $HOME/.cache/ccache From 9aad860386ad853e610cde9e1308403a55490df8 Mon Sep 17 00:00:00 2001 From: tom Date: Fri, 27 Feb 2026 11:20:12 +0000 Subject: [PATCH 13/29] try to hit cache --- .github/workflows/tests.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index a0b5b5c..2feb667 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -30,7 +30,7 @@ jobs: - if: ${{ steps.cache-ccache.outputs.cache-hit == 'true' }} name: Report on cache continue-on-error: true - run: echo "cache hit yes" + run: echo "cache hit" - name: Deps run: | From 1380f917465b57a73bc7110e2d9326d45e26a9de Mon Sep 17 00:00:00 2001 From: tom Date: Fri, 27 Feb 2026 11:41:43 +0000 Subject: [PATCH 14/29] do ccache locally --- .github/workflows/tests.yml | 8 ++++---- .gitignore | 1 + 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 2feb667..d7f88e1 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -22,10 +22,10 @@ jobs: id: cache-ccache uses: actions/cache@v4 with: - path: $HOME/.cache - key: ccache + path: ccache + key: ccache-cache restore-keys: | - $HOME/.cache/ccache + ccache-cache - if: ${{ steps.cache-ccache.outputs.cache-hit == 'true' }} name: Report on cache @@ -44,7 +44,7 @@ jobs: - name: Configure CMake # Configure CMake in a 'build' subdirectory. - run: cmake --preset debug -DCMAKE_C_COMPILER_LAUNCHER=ccache -DCMAKE_CXX_COMPILER_LAUNCHER=ccache + run: CCACHE_DIR=$PWD/ccache cmake --preset debug -DCMAKE_C_COMPILER_LAUNCHER=ccache -DCMAKE_CXX_COMPILER_LAUNCHER=ccache - name: Build # Build your program with the given configuration diff --git a/.gitignore b/.gitignore index 5c5bb4b..7468972 100644 --- a/.gitignore +++ b/.gitignore @@ -13,4 +13,5 @@ Debug Release .cache +ccache # .zed \ No newline at end of file From 8caf2a53f8f712da54f51015e37d5ad1347a88b1 Mon Sep 17 00:00:00 2001 From: tom Date: Fri, 27 Feb 2026 11:50:11 +0000 Subject: [PATCH 15/29] check last run --- .github/workflows/tests.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index d7f88e1..496bf16 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -30,7 +30,7 @@ jobs: - if: ${{ steps.cache-ccache.outputs.cache-hit == 'true' }} name: Report on cache continue-on-error: true - run: echo "cache hit" + run: echo "cache hit fo sho" - name: Deps run: | From 989ba21ff02089e96086c81937103185fbc47d88 Mon Sep 17 00:00:00 2001 From: tom Date: Fri, 27 Feb 2026 11:52:39 +0000 Subject: [PATCH 16/29] make dir --- .github/workflows/tests.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 496bf16..f37d3f4 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -44,7 +44,7 @@ jobs: - name: Configure CMake # Configure CMake in a 'build' subdirectory. - run: CCACHE_DIR=$PWD/ccache cmake --preset debug -DCMAKE_C_COMPILER_LAUNCHER=ccache -DCMAKE_CXX_COMPILER_LAUNCHER=ccache + run: mkidr ccache && CCACHE_DIR=$PWD/ccache cmake --preset debug -DCMAKE_C_COMPILER_LAUNCHER=ccache -DCMAKE_CXX_COMPILER_LAUNCHER=ccache - name: Build # Build your program with the given configuration From 17dd2133b6a6f524de16fb21f3bb55216d4a956b Mon Sep 17 00:00:00 2001 From: tom Date: Fri, 27 Feb 2026 11:57:56 +0000 Subject: [PATCH 17/29] fix yaml --- .github/workflows/tests.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index f37d3f4..a32c433 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -30,7 +30,7 @@ jobs: - if: ${{ steps.cache-ccache.outputs.cache-hit == 'true' }} name: Report on cache continue-on-error: true - run: echo "cache hit fo sho" + run: echo "cache hit" - name: Deps run: | @@ -44,7 +44,7 @@ jobs: - name: Configure CMake # Configure CMake in a 'build' subdirectory. - run: mkidr ccache && CCACHE_DIR=$PWD/ccache cmake --preset debug -DCMAKE_C_COMPILER_LAUNCHER=ccache -DCMAKE_CXX_COMPILER_LAUNCHER=ccache + run: mkdir ccache && CCACHE_DIR=$PWD/ccache cmake --preset debug -DCMAKE_C_COMPILER_LAUNCHER=ccache -DCMAKE_CXX_COMPILER_LAUNCHER=ccache - name: Build # Build your program with the given configuration From 0b109cf68cc4fe31389c483b3813049bce8b29f7 Mon Sep 17 00:00:00 2001 From: tom Date: Fri, 27 Feb 2026 12:03:19 +0000 Subject: [PATCH 18/29] test cache find --- .github/workflows/tests.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index a32c433..a100498 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -30,7 +30,7 @@ jobs: - if: ${{ steps.cache-ccache.outputs.cache-hit == 'true' }} name: Report on cache continue-on-error: true - run: echo "cache hit" + run: echo "cache hit good" - name: Deps run: | From 581c405d940296cb44c5ec560e24e9eb3ebc909e Mon Sep 17 00:00:00 2001 From: tom Date: Fri, 27 Feb 2026 12:06:26 +0000 Subject: [PATCH 19/29] mkdir if not exists --- .github/workflows/tests.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index a100498..afa929f 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -44,7 +44,7 @@ jobs: - name: Configure CMake # Configure CMake in a 'build' subdirectory. - run: mkdir ccache && CCACHE_DIR=$PWD/ccache cmake --preset debug -DCMAKE_C_COMPILER_LAUNCHER=ccache -DCMAKE_CXX_COMPILER_LAUNCHER=ccache + run: mkdir -p ccache && CCACHE_DIR=$PWD/ccache cmake --preset debug -DCMAKE_C_COMPILER_LAUNCHER=ccache -DCMAKE_CXX_COMPILER_LAUNCHER=ccache - name: Build # Build your program with the given configuration From c01414fda142a02350ac300f4f2d75d90e37a8e1 Mon Sep 17 00:00:00 2001 From: tom Date: Fri, 27 Feb 2026 12:21:13 +0000 Subject: [PATCH 20/29] list cache contents --- .github/workflows/tests.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index afa929f..4e6a835 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -30,7 +30,7 @@ jobs: - if: ${{ steps.cache-ccache.outputs.cache-hit == 'true' }} name: Report on cache continue-on-error: true - run: echo "cache hit good" + run: ls ccache" - name: Deps run: | From 3e6c9c7f8f01bd82fe08fe3af8de3be66f0eda3a Mon Sep 17 00:00:00 2001 From: tom Date: Fri, 27 Feb 2026 12:24:57 +0000 Subject: [PATCH 21/29] list cache contents --- .github/workflows/tests.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 4e6a835..8f939d9 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -23,14 +23,14 @@ jobs: uses: actions/cache@v4 with: path: ccache - key: ccache-cache + key: ccache-cache-${{ github.sha }} restore-keys: | - ccache-cache + ccache-cache- - if: ${{ steps.cache-ccache.outputs.cache-hit == 'true' }} name: Report on cache continue-on-error: true - run: ls ccache" + run: ls ccache - name: Deps run: | From d2fb2cdc2f55efb2180dbd8a51b5a4d922a6f5c2 Mon Sep 17 00:00:00 2001 From: tom Date: Fri, 27 Feb 2026 12:30:08 +0000 Subject: [PATCH 22/29] list cache contents --- .github/workflows/tests.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 8f939d9..54367b6 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -25,6 +25,7 @@ jobs: path: ccache key: ccache-cache-${{ github.sha }} restore-keys: | + ccache-cache ccache-cache- - if: ${{ steps.cache-ccache.outputs.cache-hit == 'true' }} From 1d4274603dc0688c1a86da5dec0309ae6215c990 Mon Sep 17 00:00:00 2001 From: tom Date: Fri, 27 Feb 2026 12:32:43 +0000 Subject: [PATCH 23/29] list cache contents --- .github/workflows/tests.yml | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 54367b6..f8f3af6 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -28,9 +28,7 @@ jobs: ccache-cache ccache-cache- - - if: ${{ steps.cache-ccache.outputs.cache-hit == 'true' }} - name: Report on cache - continue-on-error: true + - name: Check cache run: ls ccache - name: Deps From b87c1eda3a2da792f857771abfb3d2096ac23053 Mon Sep 17 00:00:00 2001 From: tom Date: Fri, 27 Feb 2026 12:53:38 +0000 Subject: [PATCH 24/29] cache submodules instead --- .github/workflows/tests.yml | 25 ++++++++++--------------- index.cpp | 2 +- 2 files changed, 11 insertions(+), 16 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index f8f3af6..9129836 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -13,23 +13,19 @@ jobs: # See: https://docs.github.com/en/free-pro-team@latest/actions/learn-github-actions/managing-complex-workflows#using-a-build-matrix runs-on: ubuntu-latest + steps: - - uses: actions/checkout@v4 + + - name: Cache git folder + uses: actions/cache@v3 with: - submodules: recursive + path: checkout_path/.git + key: git-folder - - name: Cache ccache - id: cache-ccache - uses: actions/cache@v4 + - uses: actions/checkout@v4 with: - path: ccache - key: ccache-cache-${{ github.sha }} - restore-keys: | - ccache-cache - ccache-cache- + submodules: recursive - - name: Check cache - run: ls ccache - name: Deps run: | @@ -39,11 +35,10 @@ jobs: libxrandr-dev libxcursor-dev libxfixes-dev libxi-dev libxss-dev libxtst-dev \ libxkbcommon-dev libdrm-dev libgbm-dev libgl1-mesa-dev libgles2-mesa-dev \ libegl1-mesa-dev libdbus-1-dev libibus-1.0-dev libudev-dev libthai-dev \ - libpipewire-0.3-dev libwayland-dev libdecor-0-dev liburing-dev ccache - + libpipewire-0.3-dev libwayland-dev libdecor-0-dev liburing-dev - name: Configure CMake # Configure CMake in a 'build' subdirectory. - run: mkdir -p ccache && CCACHE_DIR=$PWD/ccache cmake --preset debug -DCMAKE_C_COMPILER_LAUNCHER=ccache -DCMAKE_CXX_COMPILER_LAUNCHER=ccache + run: cmake --preset debug - name: Build # Build your program with the given configuration diff --git a/index.cpp b/index.cpp index 5ffe7ac..371497c 100644 --- a/index.cpp +++ b/index.cpp @@ -281,7 +281,7 @@ int main(int argc, char** argv) } }); - + // while(!window.should_close) { From 5a04209e03c0bd05b56f79a8f18d9506c9954b34 Mon Sep 17 00:00:00 2001 From: tom Date: Fri, 27 Feb 2026 13:01:10 +0000 Subject: [PATCH 25/29] sccache instead --- .github/workflows/tests.yml | 16 ++++++++++------ .vscode/settings.json | 5 ++++- 2 files changed, 14 insertions(+), 7 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 9129836..2e698b9 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -3,6 +3,9 @@ name: CMake on a single platform on: pull_request: branches: [ "main" ] + +env: + SCCACHE_GHA_ENABLED: "true" jobs: tests: @@ -16,11 +19,12 @@ jobs: steps: - - name: Cache git folder - uses: actions/cache@v3 - with: - path: checkout_path/.git - key: git-folder + - name: Run sccache-cache + uses: mozilla-actions/sccache-action@v0.0.9 + + - name: Run sccache stat for check + shell: bash + run: ${SCCACHE_PATH} --show-stats - uses: actions/checkout@v4 with: @@ -38,7 +42,7 @@ jobs: libpipewire-0.3-dev libwayland-dev libdecor-0-dev liburing-dev - name: Configure CMake # Configure CMake in a 'build' subdirectory. - run: cmake --preset debug + run: cmake --preset debug -DCMAKE_C_COMPILER_LAUNCHER=sccache -DCMAKE_CXX_COMPILER_LAUNCHER=sccache - name: Build # Build your program with the given configuration diff --git a/.vscode/settings.json b/.vscode/settings.json index b0d0698..ca2d35d 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -1,3 +1,6 @@ { - "makefile.configureOnOpen": true + "makefile.configureOnOpen": true, + "files.exclude": { + "**/.git": false + } } \ No newline at end of file From 9ef831b9d6462b5790c10434259ae3c2ac34e4bf Mon Sep 17 00:00:00 2001 From: tom Date: Fri, 27 Feb 2026 13:14:32 +0000 Subject: [PATCH 26/29] cache submodules instead another way --- .github/workflows/tests.yml | 40 ++++++++++++++++++++++--------------- 1 file changed, 24 insertions(+), 16 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 2e698b9..bdc9a66 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -4,33 +4,40 @@ on: pull_request: branches: [ "main" ] -env: - SCCACHE_GHA_ENABLED: "true" - jobs: tests: - # The CMake configure and build commands are platform agnostic and should work equally well on Windows or Mac. # You can convert this to a matrix build if you need cross-platform coverage. # See: https://docs.github.com/en/free-pro-team@latest/actions/learn-github-actions/managing-complex-workflows#using-a-build-matrix runs-on: ubuntu-latest - - steps: + + - name: Checkout this repo + uses: actions/checkout@v4 + + - name: Get submodules cache key + id: submodules-key + uses: ./.github/actions/lstree + with: + paths: third_party/assimp,third_party/SDL,third_party/tracy - - name: Run sccache-cache - uses: mozilla-actions/sccache-action@v0.0.9 - - - name: Run sccache stat for check - shell: bash - run: ${SCCACHE_PATH} --show-stats - - - uses: actions/checkout@v4 + - name: Cache Submodules + id: cache-submodule + uses: actions/cache@v4 + with: + path: | + third_party/assimp + third_party/SDL + third_party/tracy + key: ${{ steps.submodules-key.outputs.name }} + + - name: Checkout submodules + if: steps.cache-submodule.outputs.cache-hit != 'true' + uses: actions/checkout@v4 with: submodules: recursive - - name: Deps run: | sudo apt-get install libgl1-mesa-dev build-essential git make \ @@ -40,9 +47,10 @@ jobs: libxkbcommon-dev libdrm-dev libgbm-dev libgl1-mesa-dev libgles2-mesa-dev \ libegl1-mesa-dev libdbus-1-dev libibus-1.0-dev libudev-dev libthai-dev \ libpipewire-0.3-dev libwayland-dev libdecor-0-dev liburing-dev + - name: Configure CMake # Configure CMake in a 'build' subdirectory. - run: cmake --preset debug -DCMAKE_C_COMPILER_LAUNCHER=sccache -DCMAKE_CXX_COMPILER_LAUNCHER=sccache + run: cmake --preset debug - name: Build # Build your program with the given configuration From b86393066e4ef3f1fe2c7aab3b34eaf59d8407ad Mon Sep 17 00:00:00 2001 From: tom Date: Fri, 27 Feb 2026 13:18:48 +0000 Subject: [PATCH 27/29] cache submodules instead another way --- .github/workflows/tests.yml | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index bdc9a66..0b14667 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -16,11 +16,10 @@ jobs: - name: Checkout this repo uses: actions/checkout@v4 + # N.B. this needs updating if deps change - name: Get submodules cache key id: submodules-key - uses: ./.github/actions/lstree - with: - paths: third_party/assimp,third_party/SDL,third_party/tracy + run: echo "assimp-sdl-tracy" - name: Cache Submodules id: cache-submodule @@ -47,7 +46,7 @@ jobs: libxkbcommon-dev libdrm-dev libgbm-dev libgl1-mesa-dev libgles2-mesa-dev \ libegl1-mesa-dev libdbus-1-dev libibus-1.0-dev libudev-dev libthai-dev \ libpipewire-0.3-dev libwayland-dev libdecor-0-dev liburing-dev - + - name: Configure CMake # Configure CMake in a 'build' subdirectory. run: cmake --preset debug From 62ad6de14b53494f12b5dbb66c31d58c1740ffcf Mon Sep 17 00:00:00 2001 From: tom Date: Fri, 27 Feb 2026 13:20:33 +0000 Subject: [PATCH 28/29] cache submodules instead another way --- .github/workflows/tests.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 0b14667..594eeb4 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -25,11 +25,12 @@ jobs: id: cache-submodule uses: actions/cache@v4 with: + key: ${{ steps.submodules-key.outputs.name }} path: | third_party/assimp third_party/SDL third_party/tracy - key: ${{ steps.submodules-key.outputs.name }} + - name: Checkout submodules if: steps.cache-submodule.outputs.cache-hit != 'true' From 211810493cd7c067024e32934e6424d1944d57cb Mon Sep 17 00:00:00 2001 From: tom Date: Fri, 27 Feb 2026 13:23:37 +0000 Subject: [PATCH 29/29] cache submodules instead another way --- .github/workflows/tests.yml | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 594eeb4..1252580 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -16,21 +16,12 @@ jobs: - name: Checkout this repo uses: actions/checkout@v4 - # N.B. this needs updating if deps change - - name: Get submodules cache key - id: submodules-key - run: echo "assimp-sdl-tracy" - - name: Cache Submodules id: cache-submodule uses: actions/cache@v4 with: - key: ${{ steps.submodules-key.outputs.name }} - path: | - third_party/assimp - third_party/SDL - third_party/tracy - + key: third_party + path: third_party - name: Checkout submodules if: steps.cache-submodule.outputs.cache-hit != 'true'