Skip to content

feat: add const size ringbuffer_queue implement #521

feat: add const size ringbuffer_queue implement

feat: add const size ringbuffer_queue implement #521

Workflow file for this run

name: test for pull_request
# Controls when the action will run. Triggers the workflow on push or pull request
# events but only for the master branch
on:
push:
branches-ignore:
- 'release'
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:
test:
name: test for pull_request
# The type of runner that the job will run on
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ ubuntu-20.04, ubuntu-22.04 ]
env:
CC: gcc-10
CXX: g++-10
# Steps represent a sequence of tasks that will be executed as part of the job
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- name: checkout code
uses: actions/checkout@v4
- uses: actions/cache@v4
env:
cache-name: cache-cmake-files
with:
path: |
~/.ccache
~/.cache
key: ${{ matrix.os }}-cmake-build-${{ hashFiles('CMakeLists.txt', '**/CMakeLists.txt', '**/*.cmake') }}
restore-keys: |
${{ matrix.os }}-cmake-build
${{ matrix.os }}
- name: hardwares - cpu
run: nproc; cat /proc/cpuinfo
# ensure the path and files of project
- name: ensure the path and files of project
run: sudo apt-get install tree; tree
- name: Install ccache, check gcc version
run: |
sudo add-apt-repository ppa:ubuntu-toolchain-r/test
sudo apt-get update && sudo apt-get install -y ccache
gcc --version
g++ --version
- name: prepare libopencv
run: |
sudo apt-get update && sudo apt-get install libopencv-dev
- name: Use cmake
run: cmake --version
- name: cmake prepare for compile
run: cmake -S . -B ./CMAKE_DEBUG_PATH -DCMAKE_BUILD_TYPE=DEBUG
- name: cmake compile lab_00
working-directory: ./CMAKE_DEBUG_PATH/lab_00
run: cmake --build . --config DEBUG --parallel
- name: cmake compile algorithm/2021F
working-directory: ./CMAKE_DEBUG_PATH/algorithm/2021F
run: cmake --build . --config DEBUG --parallel
- name: cmake compile algorithm/matrix
working-directory: ./CMAKE_DEBUG_PATH/algorithm/matrix
run: cmake --build . --config DEBUG --parallel
- name: cmake compile algorithm
working-directory: ./CMAKE_DEBUG_PATH/algorithm/
run: cmake --build .
- name: cmake compile basic
working-directory: ./CMAKE_DEBUG_PATH/basic
run: cmake --build . --config DEBUG --parallel
- name: cmake compile
working-directory: ./CMAKE_DEBUG_PATH
run: cmake --build . --config DEBUG --parallel
- name: cmake test
working-directory: ./CMAKE_DEBUG_PATH
run: ctest --parallel $(nproc)
- name: tree
run: tree
- name: cache configs output
run: |
ccache -p
ccache -s
# This workflow contains a single job called "build"
build:
name: test for the release script
needs: test
# The type of runner that the job will run on
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ ubuntu-20.04, ubuntu-22.04 ]
# Steps represent a sequence of tasks that will be executed as part of the job
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- name: checkout code
uses: actions/checkout@v4
# ensure the path and files of project
- name: ensure the path and files of project
run: sudo apt-get install tree; tree
- name: run script
working-directory: ./script
run: python3 file_template.py
- name: tree the packet
run: tree