Nightly Build #8
Workflow file for this run
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: Nightly Build | |
| on: | |
| push: | |
| branches: | |
| - master | |
| pull_request: | |
| branches: | |
| - master | |
| workflow_dispatch: | |
| jobs: | |
| build: | |
| name: Nightly Build on ${{ matrix.os }} | |
| runs-on: ${{ matrix.os }} | |
| strategy: | |
| matrix: | |
| os: [windows-latest, macos-latest] | |
| steps: | |
| - uses: actions/checkout@v5 | |
| with: | |
| submodules: recursive | |
| - uses: actions/checkout@v5 | |
| with: | |
| repository: floooh/sokol-tools-bin | |
| ref: "c240bd1d17d4192572ee6e0cdb6e2477e4a7df80" | |
| path: sokol-tools-bin | |
| fetch-depth: 1 | |
| - name: Setup sokol-shdc | |
| shell: bash | |
| run: | | |
| if [[ "$RUNNER_OS" == "Windows" ]]; then | |
| TARGET_DIR="C:/Windows/System32" | |
| SHDC_BINARY="sokol-shdc.exe" | |
| FIND_PATH="bin/win32" | |
| elif [[ "$RUNNER_OS" == "macOS" ]]; then | |
| TARGET_DIR="/usr/local/bin" | |
| SHDC_BINARY="sokol-shdc" | |
| FIND_PATH="bin/osx_arm64" | |
| else # Linux | |
| TARGET_DIR="/usr/local/bin" | |
| SHDC_BINARY="sokol-shdc" | |
| FIND_PATH="bin/linux" | |
| fi | |
| echo "Setting up sokol-tools from sokol-tools-bin/$FIND_PATH" | |
| find sokol-tools-bin/$FIND_PATH -name $SHDC_BINARY -exec cp {} $TARGET_DIR \; | |
| $SHDC_BINARY -h | |
| - uses: yuchanns/actions-luamake@v1.0.0 | |
| with: | |
| luamake-version: "5bedfce66f075a9f68b1475747738b81b3b41c25" | |
| - name: Build | |
| shell: bash | |
| id: build | |
| run: | | |
| luamake precompile | |
| luamake soluna | |
| if [[ "$RUNNER_OS" == "Windows" ]]; then | |
| SOLUNA_BINARY="soluna.exe" | |
| else | |
| SOLUNA_BINARY="soluna" | |
| fi | |
| SOLUNA_PATH=$(find bin -name $SOLUNA_BINARY | head -n 1) | |
| echo "SOLUNA_PATH=$SOLUNA_PATH" >> $GITHUB_OUTPUT | |
| echo "SOLUNA_BINARY=$SOLUNA_BINARY" >> $GITHUB_OUTPUT | |
| - name: Validate Build | |
| shell: bash | |
| run: | | |
| echo "Validating ${{ steps.build.outputs.SOLUNA_PATH }}" | |
| ${{ steps.build.outputs.SOLUNA_PATH }} test/hello.game | |
| - uses: actions/upload-artifact@v4 | |
| name: Upload | |
| with: | |
| name: "soluna-${{ matrix.os }}-${{ steps.build.outputs.SOLUNA_BINARY }}" | |
| if-no-files-found: "error" | |
| path: "${{ steps.build.outputs.SOLUNA_PATH }}" | |
| overwrite: "true" |