From c939ca09101e24aacc493cfb726d2ae14cc3fbfa Mon Sep 17 00:00:00 2001 From: "Jeffrey C. Ollie" Date: Sun, 30 Aug 2026 10:40:21 -0500 Subject: [PATCH] add Forgejo Actions test workflow Replaces the removed tangled CI: check formatting, REUSE compliance, run the tests, and build the API docs, all through the flake dev shell on the nixos runner. Also adds the missing SPDX header to src/main.zig so the REUSE check passes. Co-Authored-By: Claude Fable 5 Claude-Session: https://claude.ai/code/session_01N46mD8544YMCkkJ5Bafrmw --- .forgejo/workflows/test.yaml | 30 ++++++++++++++++++++++++++++++ src/main.zig | 3 +++ 2 files changed, 33 insertions(+) create mode 100644 .forgejo/workflows/test.yaml diff --git a/.forgejo/workflows/test.yaml b/.forgejo/workflows/test.yaml new file mode 100644 index 0000000..3f771d1 --- /dev/null +++ b/.forgejo/workflows/test.yaml @@ -0,0 +1,30 @@ +# SPDX-FileCopyrightText: © 2026 Jeffrey C. Ollie +# SPDX-License-Identifier: MIT + +name: test + +on: + push: + workflow_dispatch: + +jobs: + test: + runs-on: nixos + env: + ZIG_LOCAL_CACHE_DIR: /zig/local-cache + ZIG_GLOBAL_CACHE_DIR: /zig/global-cache + steps: + - name: Check out + uses: actions/checkout@v4 + + - name: Check formatting + run: nix develop .#default -c zig fmt --check . + + - name: Check REUSE compliance + run: nix develop .#default -c reuse lint + + - name: Run tests + run: nix develop .#default -c zig build test + + - name: Build API docs + run: nix develop .#default -c zig build docs diff --git a/src/main.zig b/src/main.zig index aac2879..21756f1 100644 --- a/src/main.zig +++ b/src/main.zig @@ -1,3 +1,6 @@ +// SPDX-FileCopyrightText: © 2025 Jeffrey C. Ollie +// SPDX-License-Identifier: MIT + const std = @import("std"); const UUID = @import("uuid").UUID; -- 2.51.2