Skip to main content

Zig

Running the pre-built zig pipeline directly

Run the following command to run the pre-built Zig pipeline without having to initialize a project:

fluentci run zig build

Add Zig Pipeline to your project

Run the following command to add Zig pipeline to your project:

fluentci init -t zig

This will create a .fluentci directory in your project, feel free to customize the pipeline for your needs. You can then run the following command to start the pipeline:

fluentci run .

Environment variables

VariableDescription
ZIG_VERSIONThe version of Zig to use. Defaults to 0.10.1

Jobs

JobDescription
buildbuild your project
testRun your tests

Programmatic usage

You can also use this pipeline programmatically:

import { test, build } from "jsr:@fluentci/zig";

await test();
await build();

CI/CD pipeline integrations

The following examples show how to integrate FluentCI with popular CI providers to build and test Zig applications:

ci.yml
name: ci
on:
push:
branches:
- main
jobs:
tasks:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Setup Fluent CI
uses: fluentci-io/setup-fluentci@v5
- name: test
run: fluentci run --wasm zig test
- name: build
run: fluentci run --wasm zig build