# Hejsil/zig-clap

Command line argument parsing library

Repository: https://github.com/Hejsil/zig-clap
Canonical: https://ross.abutalabs.com/products/zig-clap
Language: Zig
License: MIT
License Family: permissive
Topics: zig-package, argument-parser, argument-parsing, command-line, command-line-parser, parsed-arguments, ziglang
Last push: 2026-06-13T09:32:06+00:00

## Health v2 (maintenance only)
Score: 76/100 (v2, computed 2026-09-02T17:46:02.011165+00:00)
- activity 87, release rhythm 48, longevity 100
- inputs: {"age_days": 3094, "days_push": 81, "days_rel": 135, "gap_med": 205.0, "n_releases_24m": 3}
- flags: none
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 1604, forks 98 (observed 2026-08-28T04:05:09.949674+00:00)

## What it is
zig-clap is a simple and easy-to-use command line argument parsing library for Zig. It supports short and long arguments, chained flags, multiple value-passing styles, and help message generation and parsing.

## Use cases
- parse command line arguments in a zig program
- generate help messages from parameter specifications
- handle short and long cli flags with values
- support chained flags like -abc in a cli tool
- parse help text back into parameter specifications

## When to choose
- you are writing a command line tool in Zig and need argument parsing
- you want automatic help message generation from parameter specs
- you need flexible value-passing syntaxes like -a=100 or -a100

## When to avoid
- your project is not written in Zig
- you need declarative argument parsing with code generation for other languages

## Facets
- artifact type: library
- maturity: active
- function: parser, cli, developer-tools
- domain: developer-tools, parsers
- platform: cli, cross-platform
- tags: argument-parsing, zig, command-line-parser, command-line

## Member repositories
- Hejsil/zig-clap (main) score 76

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:05:09.949674+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-30T03:52:18.456118+00:00, confidence not recorded.
  - readme: https://github.com/Hejsil/zig-clap (fetched 2026-08-28T04:05:09.949674+00:00, sha 89042c150f18)
- Data as of 2026-08-30T08:39:29.467469+00:00.
