Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
88d17a1
Update to Zig 0.16/0.17 and SQLite 3.49.2
samooth Aug 28, 2026
65dd8de
ci: bump actions/checkout to v5
samooth Aug 28, 2026
b5e9c38
docs: update Zig release support for 0.16.0 and 0.17.0
samooth Aug 28, 2026
da302fa
ci: remove paths filter so CI triggers on any push
samooth Aug 28, 2026
f39809e
build: replace std.meta.fields with @typeInfo(T)."struct".fields
samooth Aug 28, 2026
e6feff9
chore: trigger workflow
samooth Aug 28, 2026
f91f671
fix: Zig 0.17 compatibility updates
samooth Aug 28, 2026
5fdb333
ci: use local setup-zig action and remove external cache
samooth Aug 28, 2026
c481f39
ci: use local checkout action to comply with samooth-only actions policy
samooth Aug 28, 2026
6c691e1
ci: restore actions/checkout@v5 and mlugg/setup-zig@v2
samooth Aug 28, 2026
554953d
fix: Zig 0.16/0.17 compatibility fixes
samooth Aug 28, 2026
ec9b0b9
ci: remove unused local action directories
samooth Aug 28, 2026
f20dcaa
build: fix @typeInfo syntax for Zig 0.17 compatibility
samooth Aug 28, 2026
8f7cd22
ci: fix workflow to use 0.16.0 and master (0.17.0 doesn't exist yet)
samooth Aug 28, 2026
0178036
fix: Zig 0.17 compatibility with b.addTranslateC() and @intFromEnum/@…
samooth Aug 29, 2026
dea64bc
fix: Zig 0.17 compatibility with b.addTranslateC() and @intFromEnum/@…
samooth Aug 29, 2026
9dc0c6b
style: format build.zig
samooth Aug 29, 2026
1d4594f
ci: fix lint job to only run on 0.16.0 (master has different fmt rules)
samooth Aug 29, 2026
de55c51
ci: restrict test matrix - only test cross-compilation on 0.16.0, tes…
samooth Aug 29, 2026
46f8302
fix: update SQLite hash to match actual fetched package
samooth Aug 29, 2026
c1dd4d4
fix: Zig 0.17 lang.Type compatibility and Windows CI
samooth Aug 29, 2026
5a13749
docs: add CI and license badges to README
samooth Aug 29, 2026
2124d42
fix: Preprocessor rewrite for Zig 0.16/0.17 consumer-path
samooth Aug 30, 2026
2cdddf7
fix: DynamicStatement.all ArrayList initialization (closes #208)
samooth Sep 10, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
46 changes: 19 additions & 27 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -1,66 +1,58 @@
name: CI

on:
create:
push:
branches: master
paths:
- '**.zig'
branches: [master]
pull_request:
schedule:
- cron: "0 13 * * *"
workflow_dispatch:

concurrency:
group: ci-${{ github.ref }}
cancel-in-progress: true

jobs:
lint:
strategy:
fail-fast: false
matrix:
# 0.16 fmt cannot parse @fromBackingInt/@backingInt (0.17-renamed builtins) and
# 0.17 fmt rewrites @enumFromInt/@intFromEnum to those new names, so no single
# source can satisfy both formatters; lint with 0.16.0 only.
zig_version: ["0.16.0"]
runs-on: ubuntu-24.04
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@v5
- uses: mlugg/setup-zig@v2
with:
version: 0.16.0
- run: zig fmt --check *.zig
version: ${{ matrix.zig_version }}
- run: zig fmt --check *.zig c/*.zig build.zig

test-in-memory:
strategy:
fail-fast: false
matrix:
os: [ubuntu-24.04, windows-latest, macos-latest]
zig_version: ["0.16.0", "master"]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout repository
uses: actions/checkout@v4
uses: actions/checkout@v5

- name: Setup zig
uses: mlugg/setup-zig@v2
with:
version: 0.16.0
version: ${{ matrix.zig_version }}
use-cache: true
cache-size-limit: 2048

- name: Install qemu
if: ${{ matrix.os == 'ubuntu-24.04' }}
run: |
sudo apt-get update -y && sudo apt-get install -y qemu-user-binfmt

- name: Restore cache
uses: actions/cache@v4
with:
path: |
zig-cache
~/.cache/zig
key: ${{ runner.os }}-${{ matrix.os }}-zig-${{ github.sha }}
restore-keys: ${{ runner.os }}-${{ matrix.os }}-zig-

- name: Run Tests in memory
if: ${{ matrix.os == 'ubuntu-24.04' }}
run: |
mkdir -p $ZIG_GLOBAL_CACHE_DIR/tmp
mkdir -p "$ZIG_GLOBAL_CACHE_DIR/tmp"
zig build test -Dci=true -Din_memory=true --summary all -fqemu -fwine
- name: Run Tests in memory
if: ${{ matrix.os != 'ubuntu-24.04' }}
shell: bash
run: |
mkdir -p $ZIG_GLOBAL_CACHE_DIR/tmp
mkdir -p "$ZIG_GLOBAL_CACHE_DIR/tmp"
zig build test -Dci=true -Din_memory=true --summary all
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,5 @@ core.*
/fuzz/outputs
.DS_Store
/zig-pkg
# Host binary built by the build script (the preprocessor)
/zig-sqlite-preprocess
7 changes: 6 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
# zig-sqlite

[![CI](https://github.com/samooth/zig-sqlite/actions/workflows/main.yml/badge.svg)](https://github.com/samooth/zig-sqlite/actions/workflows/main.yml)
[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](./LICENSE)

This package is a thin wrapper around [sqlite](https://sqlite.org/index.html)'s C API.

_Maintainer note_: I'm currently on a break working with Zig and don't intend to work on new features for zig-sqlite.
Expand All @@ -15,7 +18,8 @@ If you use this library, expect to have to make changes when you update the code

`zig-sqlite` follows Zig's release structure:
- [master](https://github.com/vrischmann/zig-sqlite) tracks Zig master
- [zig-0.15.1](https://github.com/vrischmann/zig-sqlite/tree/zig-0.15.1) tracks Zig 0.15.1
- [zig-0.17.0](https://github.com/vrischmann/zig-sqlite/tree/zig-0.17.0) tracks Zig 0.17.0
- [zig-0.16.0](https://github.com/vrischmann/zig-sqlite/tree/zig-0.16.0) tracks Zig 0.16.0

The plan is to support releases once Zig 1.0 is released but this can still change.

Expand Down Expand Up @@ -650,3 +654,4 @@ The `finalize` function is called once at the end.

The context (2nd argument of `createAggregateFunction`) can be whatever you want; both the `step` and `finalize` functions must
have their first argument of the same type as the context.

Loading