From 54cfa1888e13d0872b5411e83d3d45925f2687ee Mon Sep 17 00:00:00 2001 From: "Max P." Date: Tue, 27 May 2025 14:56:14 +0200 Subject: [PATCH] feat(ci): enhance CI workflow with granular steps and error handling - Add separate steps for formatting, linting, testing, and benchmarking - Introduce failure detection to halt workflow on step failure - Improve maintainability and visibility of CI process outcomes --- .gitea/workflows/ci.yml | 36 +++++++++++++++++++++++++++++------- 1 file changed, 29 insertions(+), 7 deletions(-) diff --git a/.gitea/workflows/ci.yml b/.gitea/workflows/ci.yml index a28dbd6..7dce726 100644 --- a/.gitea/workflows/ci.yml +++ b/.gitea/workflows/ci.yml @@ -17,14 +17,36 @@ jobs: steps: - uses: actions/checkout@v4 - - name: Set up Deno - uses: denoland/setup-deno@v1 + - uses: denoland/setup-deno@v1 with: deno-version: v2.x - - name: Run CI Checks + - name: Format + id: format + continue-on-error: true + run: deno task fmt + + - name: Lint + id: lint + continue-on-error: true + run: deno task lint + + - name: Test + id: test + continue-on-error: true + run: deno task test + + - name: Benchmark + id: benchmark + continue-on-error: true + run: deno task benchmark + + - name: Fail if any step failed + if: | + steps.format.outcome != 'success' || + steps.lint.outcome != 'success' || + steps.test.outcome != 'success' || + steps.benchmark.outcome != 'success' run: | - deno task fmt - deno task lint - deno task test - deno task benchmark + echo "::error::One or more steps failed" + exit 1