upgrade: version to 0.17.0 #293
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: Windows | |
| on: | |
| push: | |
| release: | |
| types: [published] | |
| env: | |
| PHP_EXT: zstd | |
| PHP_EXT_VERSION: ${{ github.event.release.tag_name }} | |
| BIN_SDK_VER: 2.5.0 | |
| jobs: | |
| ci: | |
| permissions: | |
| contents: read | |
| strategy: | |
| matrix: | |
| php: | |
| - '8.5' | |
| - '8.4' | |
| - '8.3' | |
| - '8.2' | |
| - '8.1' | |
| arch: | |
| - x64 | |
| - x86 | |
| ts: | |
| - 'nts' | |
| - 'ts' | |
| vs: | |
| - vs16 | |
| - vs17 | |
| library: | |
| - false | |
| - true | |
| apcu: | |
| - '' | |
| - 'apcu' | |
| exclude: | |
| - php: '8.5' | |
| vs: vs16 | |
| - php: '8.5' | |
| vs: vs17 | |
| apcu: 'apcu' | |
| - php: '8.4' | |
| vs: vs16 | |
| - php: '8.4' | |
| vs: vs17 | |
| apcu: 'apcu' # Doesn't exist | |
| - php: '8.3' | |
| vs: vs17 | |
| - php: '8.2' | |
| vs: vs17 | |
| - php: '8.1' | |
| vs: vs17 | |
| runs-on: windows-latest | |
| env: | |
| PHP_VER: ${{ matrix.php }} | |
| PECL_APCU: ${{ matrix.apcu }} | |
| VS: ${{ matrix.vs }} | |
| ARCH: ${{ matrix.arch }} | |
| TS: ${{ matrix.ts }} | |
| if: contains(github.event.head_commit.message, 'ci skip') == false | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 | |
| with: | |
| persist-credentials: false | |
| set-safe-directory: true | |
| submodules: ${{ ! matrix.library }} | |
| token: ${{ github.token }} | |
| - name: Set up MSVC Developer Command Prompt | |
| uses: ilammy/msvc-dev-cmd@0b201ec74fa43914dc39ae48a89fd1d8cb592756 # v1.13.0 | |
| if: ${{ matrix.vs == 'vs17' }} | |
| with: | |
| arch: ${{ matrix.arch }} | |
| toolset: '14.44' | |
| - name: Install dependency library | |
| run: .\.github\workflows\vcpkg.ps1 | |
| shell: pwsh | |
| env: | |
| VCPKG_LIBRARY: zstd | |
| if: ${{ matrix.library }} | |
| - uses: actions/cache@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5.0.5 | |
| with: | |
| path: | | |
| C:\php\php-*.zip | |
| key: ${{ runner.os }}-php-${{ matrix.php }}-${{ matrix.ts }}-${{ matrix.vs }}-${{ matrix.arch }} | |
| restore-keys: | | |
| ${{ runner.os }}-php- | |
| - name: Install build command | |
| run: .\.github\workflows\install.ps1 | |
| shell: pwsh | |
| - name: Build | |
| run: .\.github\workflows\build.ps1 | |
| shell: pwsh | |
| - name: Test | |
| run: .\.github\workflows\test.ps1 | |
| shell: pwsh | |
| env: | |
| REPORT_EXIT_STATUS: 1 | |
| NO_INTERACTION: 1 | |
| - if: ${{ github.event_name == 'release' && matrix.library == false && matrix.apcu == '' }} | |
| name: Archive DLL | |
| run: |- | |
| Copy-Item .\php_${{ env.PHP_EXT }}.dll .\$env:EXT_NAME.dll | |
| Compress-Archive -Path .\$env:EXT_NAME.dll -Destination .\$env:EXT_NAME.zip | |
| shell: pwsh | |
| env: | |
| EXT_NAME: php_${{ env.PHP_EXT }}-${{ env.PHP_EXT_VERSION }}-${{ matrix.php }}-${{ matrix.ts }}-${{ matrix.vs }}-${{ matrix.arch == 'x64' && 'x86_64' || matrix.arch }} | |
| - if: ${{ github.event_name == 'release' && matrix.library == false && matrix.apcu == '' }} | |
| name: Store archive DLL | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1 | |
| with: | |
| name: ${{ env.PHP_EXT_VERSION }}-${{ matrix.php }}-${{ matrix.ts }}-${{ matrix.vs }}-${{ matrix.arch == 'x64' && 'x86_64' || matrix.arch }} | |
| path: .\php_${{ env.PHP_EXT }}-${{ env.PHP_EXT_VERSION }}-${{ matrix.php }}-${{ matrix.ts }}-${{ matrix.vs }}-${{ matrix.arch == 'x64' && 'x86_64' || matrix.arch }}.zip | |
| overwrite: true | |
| release: | |
| permissions: | |
| contents: write | |
| needs: ci | |
| runs-on: ubuntu-latest | |
| if: ${{ github.event_name == 'release' }} | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 | |
| with: | |
| persist-credentials: false | |
| set-safe-directory: true | |
| token: ${{ github.token }} | |
| - name: Get artifacts | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8.0.1 | |
| with: | |
| path: artifacts | |
| merge-multiple: true | |
| - name: Upload artifacts | |
| run: gh release upload ${{ env.PHP_EXT_VERSION }} artifacts/php* --clobber | |
| shell: bash | |
| env: | |
| GH_TOKEN: ${{ github.token }} |