Attempt to use curl that doesn't choke on unavailable cert revocation servers (WIP) #119
This file contains 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: CI | |
on: | |
push: | |
branches: | |
- master | |
paths: ['.github/workflows/build.yml', '**/CMakeLists.txt', '**/*.hpp', '**/*.cpp'] | |
pull_request: | |
types: [opened, synchronize, reopened] | |
paths: ['.github/workflows/build.yml', '**/CMakeLists.txt', '**/*.hpp', '**/*.cpp'] | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.head_ref && github.ref || github.run_id }} | |
# group: ${{ github.workflow }}-${{ github.head_ref && github.ref || github.run_id }}-${{ matrix.setup.os }}-${{ matrix.setup.build }}-${{ matrix.type }} | |
# cancel-in-progress: true | |
jobs: | |
build_and_test: | |
strategy: | |
fail-fast: false | |
matrix: | |
setup: | |
- os: windows-latest | |
build: 'default' | |
defines: '' | |
test: true | |
- os: windows-latest | |
build: 'llvm-arm64' | |
defines: '-G "Ninja Multi-Config" -D CMAKE_TOOLCHAIN_FILE=cmake/arm64-windows-llvm.cmake' | |
test: false | |
- os: windows-latest | |
build: 'msvc-arm64' | |
defines: '-G "Ninja Multi-Config" -D CMAKE_TOOLCHAIN_FILE=cmake/arm64-windows-msvc.cmake' | |
test: true | |
- os: macos-latest | |
build: default | |
defines: '' | |
test: true | |
- os: ubuntu-latest | |
build: default | |
defines: '' | |
test: true | |
type: [ | |
Release, | |
Debug, | |
] | |
runs-on: ${{ matrix.setup.os }} | |
name: ${{ matrix.setup.os }}-${{ matrix.setup.build }}-${{ matrix.type }} | |
timeout-minutes: 30 | |
steps: | |
- name: Clone | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Check curl version BEFORE | |
if: ${{ matrix.setup.os == 'windows-latest' }} | |
run: | | |
"C:\Program Files\Git\bin\sh.exe" -xc "curl --version" | |
- name: Install Choco Deps | |
if: ${{ matrix.setup.os == 'windows-latest' }} | |
run: | | |
choco install curl --yes | |
echo "C:\ProgramData\chocolatey\bin" >> $GITHUB_PATH | |
curl --version | |
- name: Check curl version AFTER | |
if: ${{ matrix.setup.os == 'windows-latest' }} | |
run: | | |
"C:\Program Files\Git\bin\sh.exe" -xc "curl --version" | |
- name: ccache | |
uses: hendrikmuhs/[email protected] | |
with: | |
key: ${{ matrix.setup.os }}-${{ matrix.setup.build }}-${{ matrix.type }} | |
- name: Set up CMake | |
uses: lukka/get-cmake@latest | |
- name: Set up Python | |
uses: actions/setup-python@v5 | |
with: | |
python-version: '3.12' | |
cache: 'pip' | |
- name: Install Python deps | |
run: pip install -r requirements.txt | |
- name: Configure CMake | |
env: | |
HF_TOKEN: ${{ secrets.HF_TOKEN }} | |
run: cmake -B ${{github.workspace}}/build ${{ matrix.setup.defines }} -DCMAKE_BUILD_TYPE=${{ matrix.type }} | |
- name: Build | |
run: cmake --build ${{github.workspace}}/build --config ${{ matrix.type }} --parallel | |
- name: Test | |
if: ${{ matrix.setup.test }} | |
run: ctest --test-dir build --output-on-failure --verbose -C ${{ matrix.type }} |