Skip to content

Try a different way to get Conan in GitHub Actions #321

Try a different way to get Conan in GitHub Actions

Try a different way to get Conan in GitHub Actions #321

Workflow file for this run

name: Build
env:
CONAN_REVISIONS_ENABLED: 1
CONAN_NON_INTERACTIVE: True
on: [push, workflow_dispatch]
jobs:
cmake-on-linux:
name: cmake
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-20.04]
build_type: [Debug, Release]
steps:
- uses: actions/checkout@v2
- name: Install prerequisites
run: |
sudo pip3 install --upgrade setuptools pip
sudo pip3 install conan
- name: Configure and build
run: |
cmake . -B build -DCMAKE_BUILD_TYPE=${{matrix.build_type}} -DPROXYFMU_BUILD_EXAMPLES=ON -DPROXYFMU_BUILD_TESTS=ON
cmake --build build
- name: Test
run: |
cd build/tests
ctest --output-on-failure --extra-verbose
- uses: actions/upload-artifact@v2
if: matrix.build_type == 'Release'
with:
name: proxyfmu
path: build/bin/proxyfmu*
cmake-on-windows:
name: cmake
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [windows-2019]
build_type: [Debug, Release]
steps:
- uses: actions/checkout@v2
- name: Install prerequisites
run: |
pip3 install --upgrade setuptools pip
pip3 install conan
- name: Configure and build
run: |
cmake . -A x64 -B build -DCMAKE_BUILD_TYPE=${{matrix.build_type}} -DPROXYFMU_BUILD_EXAMPLES=ON -DPROXYFMU_BUILD_TESTS=ON
cmake --build build --config ${{ matrix.build_type }}
- name: Test
run: |
cd build/tests
ctest -C ${{ matrix.build_type }} --output-on-failure --extra-verbose
- uses: actions/upload-artifact@v2
if: matrix.build_type == 'Release'
with:
name: proxyfmu
path: build/bin/proxyfmu*