forked from mpusz/mp-units
merge branch master
This commit is contained in:
@@ -35,35 +35,44 @@ on:
|
||||
- "docs/**"
|
||||
- "src/**"
|
||||
- "example/**"
|
||||
|
||||
env:
|
||||
CC: gcc-10
|
||||
CXX: g++-10
|
||||
CMAKE_GENERATOR: Ninja
|
||||
CONAN_CMAKE_GENERATOR: Ninja
|
||||
|
||||
jobs:
|
||||
docs:
|
||||
name: Generate documentation
|
||||
runs-on: ubuntu-20.04
|
||||
runs-on: ${{ matrix.os }}
|
||||
env:
|
||||
CC: gcc-10
|
||||
CXX: g++-10
|
||||
CMAKE_GENERATOR: Ninja
|
||||
CONAN_CMAKE_GENERATOR: Ninja
|
||||
OS: ubuntu-22.04
|
||||
BUILD_TYPE: Debug
|
||||
COMPILER_TYPE: GCC
|
||||
COMPILER_VERSION: 10
|
||||
STDLIB: libstdc++11
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
os: ["ubuntu-latest"]
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- uses: actions/checkout@v3
|
||||
- name: Cache Conan data
|
||||
uses: actions/cache@v2
|
||||
uses: actions/cache@v3
|
||||
env:
|
||||
cache-name: cache-conan-data
|
||||
with:
|
||||
path: ~/.conan/data
|
||||
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/metadata.json') }}
|
||||
path: ~/.conan2/p
|
||||
key: build-${{ matrix.os }}-$BUILD_TYPE-$COMPILER_TYPE-$COMPILER_VERSION-$STDLIB-docs
|
||||
restore-keys: |
|
||||
${{ runner.os }}-build-${{ env.cache-name }}-
|
||||
${{ runner.os }}-build-
|
||||
${{ runner.os }}-
|
||||
build-${{ matrix.os }}-$BUILD_TYPE-$COMPILER_TYPE-$COMPILER_VERSION-$STDLIB
|
||||
build-${{ matrix.os }}-$BUILD_TYPE-$COMPILER_TYPE-$COMPILER_VERSION-
|
||||
build-${{ matrix.os }}-$BUILD_TYPE-$COMPILER_TYPE-
|
||||
build-${{ matrix.os }}-$BUILD_TYPE-
|
||||
build-${{ matrix.os }}-
|
||||
- name: Install Ninja
|
||||
run: |
|
||||
sudo apt install -y ninja-build
|
||||
- name: Set up Python
|
||||
uses: actions/setup-python@v2
|
||||
uses: actions/setup-python@v4
|
||||
with:
|
||||
python-version: "3.8"
|
||||
- name: Install Python dependencies
|
||||
@@ -74,17 +83,17 @@ jobs:
|
||||
pip install -U conan
|
||||
- name: Configure Conan
|
||||
run: |
|
||||
conan config init
|
||||
conan remote add -i 0 upload https://mpusz.jfrog.io/artifactory/api/conan/conan-oss
|
||||
conan profile detect --force
|
||||
conan remote add artifactory https://mpusz.jfrog.io/artifactory/api/conan/conan-oss
|
||||
- name: Install Conan dependencies
|
||||
run: |
|
||||
conan install . -s compiler.cppstd=20 -s compiler.libcxx=libstdc++11 -c user.build:all=True -c tools.cmake.cmaketoolchain:generator="Ninja Multi-Config" -b outdated -u
|
||||
conan install . -s compiler.cppstd=20 -s compiler.libcxx=$STDLIB -c user.build:all=True -c tools.cmake.cmaketoolchain:generator="Ninja Multi-Config" -b missing
|
||||
- name: Configure CMake
|
||||
run: |
|
||||
cmake --preset default
|
||||
cmake --preset conan-default
|
||||
- name: Generate documentation
|
||||
run: |
|
||||
cmake --build --preset release --target documentation
|
||||
cmake --build --preset conan-release --target documentation
|
||||
- name: Deploy documentation
|
||||
if: github.ref == 'refs/heads/master'
|
||||
uses: peaceiris/actions-gh-pages@v3
|
||||
|
||||
Reference in New Issue
Block a user