ci[mirror]: improve branch name detection #5928
Workflow file for this run
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: Windows-MSVC-Reference | |
on: | |
push: | |
branches: | |
- 'master' | |
- 'develop' | |
- 'release/**' | |
tags: | |
- '**' | |
pull_request: | |
types: [opened,synchronize] | |
workflow_dispatch: | |
inputs: | |
debug_enabled: | |
description: 'Run the build with tmate debugging enabled by `debug_enabled` keyword (https://github.com/marketplace/actions/debugging-with-tmate)' | |
required: false | |
default: false | |
concurrency: | |
group: ${{ github.workflow }}-${{ (github.head_ref && github.ref) || github.run_id }} | |
cancel-in-progress: true | |
jobs: | |
windows_ref: | |
strategy: | |
fail-fast: false | |
matrix: | |
config: | |
# Debug shared exceeds symbol limit | |
# - {shared: "ON", build_type: "Debug", name: "reference/debug/shared"} | |
- {shared: "OFF", build_type: "Release", name: "reference/release/static"} | |
- {shared: "ON", build_type: "Release", name: "reference/release/shared"} | |
# Debug static needs too much storage | |
# - {shared: "OFF", build_type: "Debug", name: "reference/debug/static"} | |
name: msvc/${{ matrix.config.name }} | |
runs-on: [windows-latest] | |
steps: | |
- name: Checkout the latest code (shallow clone) | |
uses: actions/checkout@v4 | |
- name: Debug over SSH (tmate) | |
uses: mxschmitt/[email protected] | |
if: ${{ github.event_name == 'workflow_dispatch' && github.event.inputs.debug_enabled }} | |
with: | |
limit-access-to-actor: true | |
- name: configure | |
run: | | |
mkdir build | |
cd build | |
cmake -DBUILD_SHARED_LIBS=${{ matrix.config.shared }} -DCMAKE_CXX_FLAGS_DEBUG='/MDd /Zi /Ob1 /O1 /Od /RTC1' -DGINKGO_BUILD_CUDA=OFF -DGINKGO_BUILD_OMP=OFF .. | |
cmake --build . -j4 --config ${{ matrix.config.build_type }} | |
ctest . -C ${{ matrix.config.build_type }} --output-on-failure | |
- name: install | |
run: | | |
$env:PATH="$env:PATH;C:\Program Files (x86)\Ginkgo\bin" | |
cd build | |
cmake --install . --config ${{ matrix.config.build_type }} | |
cmake --build . --target test_install --config ${{ matrix.config.build_type }} |