Initial commit from https://devstar.cn/templates/base.git ( 2110c117966989f2d02afeb36f08481ed1c5d1b6 )

This commit is contained in:
2025-11-01 09:43:50 +00:00
repo.diff.commit e83265881b
repo.diff.stats_desc%!(EXTRA int=14, int=594, int=0)

43
.gitea/workflows/ci.yaml Normal file
repo.diff.view_file

@@ -0,0 +1,43 @@
name: CI Pipeline
on:
push:
branches:
- main
pull_request:
branches:
- main
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: 🔍 Check out repository code
uses: https://devstar.cn/actions/checkout@v4
- name: 🔧 Test Codes and Build an Artifact
run: |
set -e # 任何命令失败都停止执行
echo "Building repository code ${{ gitea.repository }}:${{ gitea.ref }}."
make
# 运行 fork 并检查退出代码
echo "Running fork..."
./fork
fork_exit_code=$?
if [ $fork_exit_code -ne 0 ]; then
echo "fork failed with exit code $fork_exit_code"
exit 1
fi
# 运行 execlp 并检查退出代码 (如果 execlp 是一个可执行文件)
echo "Running execlp..."
./execlp
execlp_exit_code=$?
if [ $execlp_exit_code -ne 0 ]; then
echo "execlp failed with exit code $execlp_exit_code"
exit 1
fi
echo "All tests passed!"
make clean