@@ -0,0 +1,63 @@
|
|||||||
|
name: klist
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches: [ main ]
|
||||||
|
pull_request:
|
||||||
|
branches: [ main ]
|
||||||
|
|
||||||
|
concurrency:
|
||||||
|
group: ${{ github.workflow }}-${{ github.ref }}
|
||||||
|
cancel-in-progress: true
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
build:
|
||||||
|
runs-on: ubuntu-26.04
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v6
|
||||||
|
|
||||||
|
- name: Cache Conan dependencies
|
||||||
|
uses: actions/cache@v3
|
||||||
|
with:
|
||||||
|
path: ~/.conan/data # Or your custom cache directory
|
||||||
|
key: ${{ runner.os }}-conan-${{ hashFiles('**/conanfile.*') }}
|
||||||
|
restore-keys: |
|
||||||
|
${{ runner.os }}-conan-
|
||||||
|
|
||||||
|
- name: Create tmp folder
|
||||||
|
run: mkdir tmp
|
||||||
|
|
||||||
|
- name: Install Conan and other dependencies
|
||||||
|
working-directory: tmp
|
||||||
|
run: |
|
||||||
|
sudo apt update
|
||||||
|
sudo apt install -y cmake
|
||||||
|
cmake --version
|
||||||
|
|
||||||
|
wget https://github.com/conan-io/conan/releases/download/2.32.0/conan-2.32.0-amd64.deb
|
||||||
|
sudo dpkg -i conan-2.32.0-amd64.deb
|
||||||
|
|
||||||
|
- name: Configure Conan
|
||||||
|
run: |
|
||||||
|
conan profile detect --force # Create a default profile
|
||||||
|
|
||||||
|
- name: Create build directory
|
||||||
|
run: mkdir build
|
||||||
|
|
||||||
|
- name: Install dependencies
|
||||||
|
working-directory: build
|
||||||
|
run: conan install .. --build=missing
|
||||||
|
|
||||||
|
- name: build project
|
||||||
|
working-directory: build
|
||||||
|
run: |
|
||||||
|
source Release/generators/conanbuild.sh
|
||||||
|
cmake .. --preset conan-release
|
||||||
|
cmake --build Release
|
||||||
|
|
||||||
|
- name: Test with CTest (optional)
|
||||||
|
working-directory: build/Release
|
||||||
|
run: ctest -C Release
|
||||||
|
|
||||||
|
|
||||||
Reference in New Issue
Block a user