Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
26 changes: 26 additions & 0 deletions .github/workflows/go.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: Go CI

on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]

jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
go-version: ['1.26'] # Update this if your go.mod uses a different version

steps:
- uses: actions/checkout@v4

- name: Set up Go
uses: actions/setup-go@v5
with:
go-version: ${{ matrix.go-version }}

- name: Test
run: go test -v -race ./...
15 changes: 13 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,16 @@ go get github.com/trycatchkamal/gauzer

---

[![Go Reference](https://pkg.go.dev/badge/github.com/trycatchkamal/gauzer.svg)](https://pkg.go.dev/github.com/trycatchkamal/gauzer)
[![Go Report Card](https://goreportcard.com/badge/github.com/trycatchkamal/gauzer)](https://goreportcard.com/report/github.com/trycatchkamal/gauzer)
[![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](https://opensource.org/licenses/MIT)
[![Build Status](https://github.com/trycatchkamal/gauzer/actions/workflows/go.yml/badge.svg)](https://github.com/trycatchkamal/gauzer/actions/workflows/go.yml)

---

## The Problem
... (rest of your README continues here)

## The Problem

Most validation libraries return errors as flat strings. That works fine until you're on-call trying to answer *"how often are users failing the age check, and with what values?"* in a production system.
Expand Down Expand Up @@ -220,10 +230,11 @@ type User struct {
| `eqfield=OtherField` | Value must equal the named sibling field. |
| `nefield=OtherField` | Value must not equal the named sibling field. |

> **v0.2.0 roadmap:** `dive` into nested structs (currently works for slices of scalars and strings), and additional cross-field rules. If a tag token is unrecognized it is silently skipped, so future tags added in minor versions will not break existing code.

---

## Roadmap
Check out the [ROADMAP](https://github.com/trycatchkamal/gauzer/blob/main/ROADMAP.md) to see what's planned for v0.2.0, including OTel metrics, nested dive, and enterprise dependency injection.

## Contributing

Bug reports and pull requests are welcome. For significant changes, open an issue first to discuss the approach.
Expand Down
13 changes: 13 additions & 0 deletions ROADMAP.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# Gauzer Roadmap

## v0.1.0 (Current)
* Drop-in struct tag replacement.
* Native `slog.LogValuer` implementation.
* OTel Span attribute adapter.
* Zero-alloc happy path (~61ns).
* Native PII masking (`mask` tag).

## v0.2.0 (Planned)
* **OTel Metrics Integration:** Adding `Int64Counter` support to the `gauzer/otel` adapter (e.g., `gauzer.validation.errors{rule="email"}`) to enable automated paging on validation spikes.
* **Dependency Injection:** Adding Functional Options to `oteladapter.New()` (e.g., `WithMeter()`) to support strict enterprise OTel provider isolation.
* **Nested `dive`:** Expanding `dive` support to validate nested struct slices (e.g., `[][]User`), not just primitive slices.
Loading