File: windows.yml

package info (click to toggle)
xtensor 0.25.0-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 6,476 kB
  • sloc: cpp: 65,302; makefile: 202; python: 171; javascript: 8
file content (63 lines) | stat: -rw-r--r-- 1,532 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
name: Windows
on:
  workflow_dispatch:
  pull_request:
  push:
    branches: [master]
concurrency:
  group: ${{ github.workflow }}-${{ github.job }}-${{ github.ref }}
  cancel-in-progress: true
defaults:
  run:
    shell: bash -e -l {0}
jobs:
  build:
    runs-on: ${{ matrix.runs-on }}
    name: ${{ matrix.sys.compiler }}
    strategy:
      fail-fast: false
      matrix:
        runs-on: [windows-latest]
        sys:
        - {compiler: default}
        - {compiler: clang}

    steps:

    - name: Setup MSVC
      if: matrix.sys.compiler == 'default'
      uses: ilammy/msvc-dev-cmd@v1

    - name: Setup clang
      if: matrix.sys.compiler == 'clang'
      run: |
        echo "CC=clang" >> $GITHUB_ENV
        echo "CXX=clang++" >> $GITHUB_ENV

    - name: Checkout code
      uses: actions/checkout@v3

    - name: Set conda environment
      uses: mamba-org/setup-micromamba@main
      with:
        environment-name: myenv
        environment-file: environment-dev.yml
        init-shell: bash
        cache-downloads: true
        create-args: |
          ninja

    - name: Configure using CMake
      run: cmake -Bbuild -DCMAKE_BUILD_TYPE:STRING=Release -DCMAKE_INSTALL_PREFIX=$CONDA_PREFIX -DBUILD_TESTS=ON -G Ninja

    - name: Install
      working-directory: build
      run: cmake --install .

    - name: Build
      working-directory: build
      run: cmake --build . --target test_xtensor_lib --parallel 8

    - name: Run tests
      working-directory: build
      run: ctest -R ^xtest$ --output-on-failure