name: Windows # Controls when the action will run. Triggers the workflow on push or pull request # events but only for the master branch on: push: branches: - master pull_request: branches: - master jobs: build: strategy: # Prevent one build from failing everything (although maybe those should be included as experimental builds instead) fail-fast: false matrix: os: [windows-2019] config: [Release] experimental: [false] name: ${{ matrix.config }} runs-on: ${{ matrix.os }} continue-on-error: ${{ matrix.experimental }} # Set some sort of timeout in the event of run-away builds. We are limited on concurrent jobs so, get rid of them. timeout-minutes: 20 env: # overrides: https://github.com/mbitsnbites/buildcache/blob/master/doc/configuration.md BUILDCACHE_MAX_CACHE_SIZE: 1000000000 # 1gb BUILDCACHE_COMPRESS_FORMAT: ZSTD BUILDCACHE_COMPRESS_LEVEL: 19 BUILDCACHE_DIRECT_MODE: true BUILDCACHE_LOG_FILE: ${{ github.workspace }}/buildcache.log steps: # NOTE - useful for debugging # - name: Dump GitHub context # env: # GITHUB_CONTEXT: ${{ toJson(github) }} # run: | # echo "$GITHUB_CONTEXT" - name: Checkout Repository uses: actions/checkout@v2 - name: Checkout Submodules run: git submodule update --init --recursive -j 2 - name: Install Dependencies run: choco install nasm - name: Setup Buildcache uses: mikehardy/buildcache-action@v1.2.2 with: cache_key: ${{ matrix.os }}-${{ matrix.config }} - name: CMake Generation shell: cmd # ideally id like everything to be powershell but running this bat file is finicky run: | call "C:/Program Files (x86)/Microsoft Visual Studio/2019/Enterprise/VC/Auxiliary/Build/vcvars64.bat" cmake -B build -G "NMake Makefiles" -DCMAKE_BUILD_TYPE=Release -DCMAKE_C_COMPILER_LAUNCHER="${{ github.workspace }}"/buildcache/bin/buildcache.exe -DCMAKE_CXX_COMPILER_LAUNCHER="${{ github.workspace }}"/buildcache/bin/buildcache.exe . - name: Build Project working-directory: ./build shell: cmd run: | call "C:/Program Files (x86)/Microsoft Visual Studio/2019/Enterprise/VC/Auxiliary/Build/vcvars64.bat" set CL=/MP nmake - name: Run Tests timeout-minutes: 5 env: NEXT_DIR: ${{ github.workspace }} FAKE_ISO_PATH: ${{ github.workspace }}/game/fake_iso.txt run: ./build/bin/goalc-test.exe --gtest_color=yes --gtest_filter="-*MANUAL_TEST*"