Repository navigation
This file contains hidden or 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: Test and Release | |
| on: [push] | |
| jobs: | |
| linux-x86_64: | |
| runs-on: ubuntu-24.04 | |
| steps: | |
| - uses: actions/checkout@v6 | |
| with: | |
| submodules: recursive | |
| - uses: extractions/setup-just@v4 | |
| - uses: laytan/setup-odin@v2 | |
| with: | |
| token: ${{ secrets.GITHUB_TOKEN }} | |
| release: dev-2026-05 | |
| - name: Install libclang, llvm, sdl2, sdl2_image | |
| uses: awalsh128/cache-apt-pkgs-action@v1 | |
| with: | |
| packages: libclang-18-dev libllvm18 libsdl2-dev libsdl2-image-dev | |
| version: 1 | |
| - name: Setup libclang and llvm symlinks | |
| run: | | |
| sudo ln -rfs /usr/lib/x86_64-linux-gnu/libclang-18.so /usr/lib/x86_64-linux-gnu/libclang.so | |
| sudo ln -rfs /usr/lib/llvm-18/lib/libLLVM.so.1 /usr/lib/libLLVM-18.so.18.1 | |
| - name: test | |
| run: just test | |
| - name: examples (olivec, tiled) | |
| run: just example olivec example tiled | |
| - name: build appimage | |
| run: | | |
| mkdir appimagetool_bin/ | |
| just install-appimagetool appimagetool_bin | |
| export PATH=$(realpath appimagetool_bin):$PATH | |
| just package | |
| - uses: actions/upload-artifact@v7 | |
| with: | |
| name: runic-linux-x86_64 | |
| path: ${{ github.workspace }}/build/package/* | |
| if-no-files-found: warn | |
| overwrite: true | |
| compression-level: 0 | |
| linux-arm64: | |
| runs-on: ubuntu-24.04-arm | |
| steps: | |
| - uses: actions/checkout@v6 | |
| with: | |
| submodules: recursive | |
| - uses: extractions/setup-just@v4 | |
| - uses: laytan/setup-odin@v2 | |
| with: | |
| token: ${{ secrets.GITHUB_TOKEN }} | |
| release: dev-2026-05 | |
| - name: Install libclang, llvm, sdl2, sdl2_image | |
| uses: awalsh128/cache-apt-pkgs-action@v1 | |
| with: | |
| packages: libclang-18-dev libllvm18 libsdl2-dev libsdl2-image-dev | |
| version: 1 | |
| - name: Setup libclang and llvm symlinks | |
| run: | | |
| sudo ln -rfs /usr/lib/aarch64-linux-gnu/libclang-18.so /usr/lib/aarch64-linux-gnu/libclang.so | |
| sudo ln -rfs /usr/lib/llvm-18/lib/libLLVM.so.1 /usr/lib/libLLVM-18.so.18.1 | |
| - name: test | |
| run: just test | |
| - name: examples (olivec, tiled) | |
| run: just example olivec example tiled | |
| - name: build appimage | |
| run: | | |
| mkdir appimagetool_bin/ | |
| just install-appimagetool appimagetool_bin | |
| export PATH=$(realpath appimagetool_bin):$PATH | |
| just package | |
| - uses: actions/upload-artifact@v7 | |
| with: | |
| name: runic-linux-aarch64 | |
| path: ${{ github.workspace }}/build/package/* | |
| if-no-files-found: warn | |
| overwrite: true | |
| compression-level: 0 | |
| windows-x86_64: | |
| runs-on: windows-2025 | |
| steps: | |
| - uses: actions/checkout@v6 | |
| with: | |
| submodules: recursive | |
| - uses: ilammy/msvc-dev-cmd@v1 | |
| - uses: extractions/setup-just@v4 | |
| - uses: laytan/setup-odin@v2 | |
| with: | |
| token: ${{ secrets.GITHUB_TOKEN }} | |
| release: dev-2026-05 | |
| - name: cache libclang.dll | |
| id: cache-libclang | |
| uses: actions/cache@v5 | |
| with: | |
| key: 'libclang.dll@v19.1.7' | |
| path: ${{ github.workspace }}/build/libclang.dll | |
| - name: download libclang.dll | |
| if: steps.cache-libclang.outputs.cache-hit != 'true' | |
| run: | | |
| mkdir build | |
| just -f shared/libclang/justfile download-library "" "..\..\build" | |
| - name: test | |
| run: just test | |
| - name: examples (olivec, tiled) | |
| run: just example olivec example tiled | |
| - name: build runic | |
| run: just | |
| - name: build runic installer | |
| uses: Minionguyjpro/Inno-Setup-Action@v1.2.8 | |
| with: | |
| path: windows_installer.iss | |
| - uses: actions/upload-artifact@v7 | |
| with: | |
| name: runic-windows-x86_64 | |
| path: ${{ github.workspace }}/build/package/* | |
| if-no-files-found: warn | |
| overwrite: true | |
| compression-level: 0 | |
| macos-arm64: | |
| runs-on: macos-14 | |
| steps: | |
| - uses: actions/checkout@v6 | |
| with: | |
| submodules: recursive | |
| - uses: extractions/setup-just@v4 | |
| - uses: laytan/setup-odin@v2 | |
| with: | |
| token: ${{ secrets.GITHUB_TOKEN }} | |
| release: dev-2026-05 | |
| - name: install llvm19, sdl2, sdl2_image, libyaml | |
| uses: Homebrew/actions/cache-homebrew-prefix@main | |
| with: | |
| install: llvm@19 sdl2 sdl2_image libyaml | |
| uninstall: true | |
| - name: test | |
| run: just test | |
| - name: examples (olivec, tiled) | |
| run: just example olivec example tiled | |
| - name: build runic | |
| run: just | |
| - name: create runic artifact | |
| run: | | |
| mkdir build/package | |
| mv build/runic build/package/runic-macos-aarch64 | |
| - uses: actions/upload-artifact@v7 | |
| with: | |
| name: runic-macos-aarch64 | |
| path: ${{ github.workspace }}/build/package/* | |
| if-no-files-found: warn | |
| overwrite: true | |
| compression-level: 0 | |
| create-release: | |
| runs-on: ubuntu-24.04 | |
| needs: [ linux-x86_64, linux-arm64, windows-x86_64, macos-arm64 ] | |
| if: startsWith(github.ref, 'refs/tags/') | |
| permissions: | |
| contents: write | |
| steps: | |
| - uses: actions/download-artifact@v8 | |
| with: | |
| pattern: 'runic*' | |
| merge-multiple: true | |
| path: artifacts | |
| - name: list | |
| run: ls -lah --color=always artifacts | |
| - uses: ncipollo/release-action@v1 | |
| with: | |
| artifacts: 'artifacts/*' | |
| body: | | |
| Automatically generated by Github Actions Run ${{ github.run_id }} | |
| generateReleaseNotes: true | |
| makeLatest: true |