No description
Find a file
2026-03-14 19:30:33 +06:00
.github/workflows ci: rebuild from source when publishing 2026-03-14 19:20:34 +06:00
example feat: upgrade temporal_rs to 0.2.0 2026-03-14 19:00:35 +06:00
pkg/temporal feat: upgrade libtemporal to v0.2.0 2026-03-14 19:29:48 +06:00
src refactor: move complexities to pkg 2026-03-14 17:31:19 +06:00
test fix: use prebuilt artifact from published lib 2026-03-14 15:54:05 +06:00
.gitignore chore: ignore lib/ binaries 2026-03-14 16:45:52 +06:00
.gitmodules feat: add wasi target 2026-02-12 01:26:36 +06:00
.tool-versions refactor: migrate to zig 0.16.0-dev 2026-02-11 14:04:50 +06:00
build.zig chore: update run step 2026-03-14 18:54:58 +06:00
build.zig.zon chore: bump version 2026-03-14 19:30:33 +06:00
LICENCE chore: improve readme 2026-01-26 12:38:42 +06:00
README.md docs: update prebuilt targets list 2026-03-14 17:00:39 +06:00
SPEC.md fix(Instant): align with spec 2026-01-23 23:57:14 +06:00

Temporalz

CI

A Zig library for working with temporal types based on the Temporal Standard.

Temporalz provides Zig bindings to the Rust-based temporal_rs library for handling dates, times, and durations with proper timezone support.

Installation

Prerequisites

  • Zig 0.16.0-dev.2860+9c5460316
  • Rust toolchain (only required if prebuilt staticlibs are not available for your platform)

Add as a Dependency

zig fetch --save git+https://github.com/nurulhudaapon/temporalz.git

Use in build.zig

Add temporalz to your executable in build.zig:

const temporalz = b.dependency("temporalz", .{
    .target = target,
    .optimize = optimize,
});

const exe = b.addExecutable(.{...});

exe.root_module.addImport("temporalz", temporalz.module("temporalz"));

Checklist (Test262)

Namespace Test262 (todo)
Instant 0/0
Duration 0/0
PlainDate 0/0
PlainTime 0/0
PlainDateTime 0/0
PlainYearMonth 0/0
PlainMonthDay 0/0
ZonedDateTime 0/0

Prebuilt

Prebuilt libraries are included for the following platforms:

  • x86_64-macos
  • aarch64-macos
  • x86_64-linux-gnu
  • aarch64-linux-gnu
  • x86_64-windows-gnu
  • aarch64-windows-gnu
  • wasm32-freestanding
  • wasm32-wasi
  • x86_64-linux-musl
  • aarch64-linux-musl
  • aarch64-linux-android
  • aarch64-ios

For other platforms, the library will build from source; you need the Rust toolchain installed.

Development

Clone the Repository

git clone https://github.com/nurulhudaapon/temporalz.git
cd temporalz

Build and Run

zig build run

Run Tests

zig build test

License

MIT