Add gitea workflow
All checks were successful
libakerror CI Build / cmake_build (push) Successful in 2m39s

This commit is contained in:
2026-06-27 08:42:08 -04:00
parent 5b1a6c2cc7
commit 4fad0cec59
3 changed files with 32 additions and 0 deletions

23
.gitea/workflows/ci.yaml Normal file
View File

@@ -0,0 +1,23 @@
name: libakerror CI Build
run-name: ${{ gitea.actor }} libakerror test
on: [push]
jobs:
cmake_build:
runs-on: ubuntu-latest
steps:
- run: echo "Triggered by ${{ gitea.event_name }} from ${{ gitea.repository }}@${{ gitea.ref }}. Building on ${{ runner.os }}."
- name: Check out repository code
uses: actions/checkout@v4
- name: dependencies
run: |
sudo apt-get update -y
sudo apt-get install -y cmake gcc moreutils
- name: build and test
run: |
mkdir installdir
cmake -S . -B build -DCMAKE_INSTALL_PREFIX=installdir
cmake --build build
cmake --install build
cmake --build build --target test
- run: echo "🍏 This job's status is ${{ job.status }}."

View File

@@ -3,6 +3,7 @@ project(akerror LANGUAGES C)
include(GNUInstallDirs)
include(CMakePackageConfigHelpers)
include(CTest)
set(AKERR_USE_STDLIB 1 CACHE BOOL "Use the C standard library")
set(akerror_install_cmakedir "${CMAKE_INSTALL_LIBDIR}/cmake/akerror")
@@ -52,6 +53,12 @@ add_test(NAME err_cleanup COMMAND test_err_cleanup)
add_test(NAME err_trace COMMAND test_err_trace)
add_test(NAME err_improper_closure COMMAND test_err_improper_closure)
set_tests_properties(
err_trace
err_improper_closure
PROPERTIES WILL_FAIL TRUE
)
target_link_libraries(test_err_catch PRIVATE akerror)
target_link_libraries(test_err_cleanup PRIVATE akerror)
target_link_libraries(test_err_trace PRIVATE akerror)

View File

@@ -2,6 +2,8 @@
This library provides a TRY/CATCH style exception handling mechanism for C.
![build badge](https://source.starfort.tech/andrew/libakerror/actions/workflows/ci.yaml/badge.svg?branch=main)
# Why?
There is nothing wrong with C as it is. This library does not claim to fix some problem with C.