CI: Use github actions for Windows CI #287
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: Checks | |
| on: [push, pull_request] | |
| jobs: | |
| windows: | |
| strategy: | |
| matrix: | |
| arch: [Win32, x64] | |
| fail-fast: false | |
| name: Windows (${{ matrix.arch }}) | |
| runs-on: windows-latest | |
| steps: | |
| - name: Get zlib info | |
| id: zlib-info | |
| run: | | |
| Out-File -FilePath $Env.GITHUB_OUTPUT -Append 'hash=' + ((git ls-remote https://github.com/MediaArea/zlib.git HEAD) -Split)[1]) | |
| Out-File -FilePath $Env.GITHUB_OUTPUT -Append 'path=' + (Get-Location) + '\zlib' | |
| - name: zlib cache | |
| id: zlib-cache | |
| uses: actions/cache@v4 | |
| with: | |
| path: ${{ steps.zlib-info.outputs.path }} | |
| key: ${{ runner.arch }}-zlib-${{ steps.zlib-info.outputs.hash }} | |
| - name: Checkout zlib | |
| if: steps.zlib-cache.outputs.cache-hit != 'true' | |
| uses: actions/checkout@v4 | |
| with: | |
| repository: MediaArea/zlib | |
| path: zlib | |
| - name: Get ZenLib info | |
| id: zenlib-info | |
| run: | | |
| Out-File -FilePath $Env.GITHUB_OUTPUT -Append 'hash=' + ((git ls-remote https://github.com/MediaArea/ZenLib.git HEAD) -Split)[1]) | |
| Out-File -FilePath $Env.GITHUB_OUTPUT -Append 'path=' + (Get-Location) + '\ZenLib' | |
| - name: ZenLib cache | |
| id: zenlib-cache | |
| uses: actions/cache@v4 | |
| with: | |
| path: ${{ steps.zenlib-info.outputs.path }} | |
| key: ${{ runner.arch }}-zenlib-${{ steps.zenlib-info.outputs.hash }} | |
| - name: Checkout ZenLib | |
| if: steps.zenlib-cache.outputs.cache-hit != 'true' | |
| uses: actions/checkout@v4 | |
| with: | |
| repository: MediaArea/ZenLib | |
| path: ZenLib | |
| - name: Get MediaInfoLib info | |
| id: mediainfolib-info | |
| run: | | |
| Out-File -FilePath $Env.GITHUB_OUTPUT -Append 'hash=' + ((git ls-remote https://github.com/MediaArea/MediaInfoLib.git HEAD) -Split)[1]) | |
| Out-File -FilePath $Env.GITHUB_OUTPUT -Append 'path=' + (Get-Location) + '\MediaInfoLib' | |
| - name: MediaInfoLib cache | |
| id: mediainfolib-cache | |
| uses: actions/cache@v4 | |
| with: | |
| path: ${{ steps.mediainfolib-info.outputs.path }} | |
| key: ${{ runner.arch }}-mediainfolib-${{ steps.mediainfolib-info.outputs.hash }} | |
| - name: Checkout MediaInfoLib | |
| if: steps.mediainfolib-cache.outputs.cache-hit != 'true' | |
| uses: actions/checkout@v4 | |
| with: | |
| repository: MediaArea/MediaInfoLib | |
| path: MediaInfoLib | |
| - name: Checkout MediaConch | |
| uses: actions/checkout@v4 | |
| with: | |
| path: MediaConch | |
| - name: Add MSBuild to PATH | |
| uses: microsoft/setup-msbuild@v2 | |
| with: | |
| msbuild-architecture: x64 | |
| - name: Build | |
| run: MSBuild /verbosity:quiet /p:Configuration=Release;Platform=${{ matrix.arch }} MediaConch\Project\MSVC2022\MediaConch.sln |