Arg is an unopinionated CLI argument parser for Node.js. It parses command line flags into an object (consumed options become properties, extra positional values go into `result._`) and supports basic types, aliases, and permissive parsing behavior. It is useful for turning `process.argv` into structured inputs for command line tools.
Project status
- Upstream activity appears dormant, with the last recorded upstream push on 2024-07-18, and the most recent tagged updates in the provided history from 2022-06-05 (5.0.2) and earlier.
- Update cadence is irregular and has lengthened over time, with updates roughly in 2020 (5.0.0), 2021 (5.0.1), and 2022 (5.0.2), and no evidence of newer updates in the provided list.
AI summary generated Today
Recent updates
5.0.2
6/5/2022Release 5.0.2 is a small patch release focused on TypeScript type definitions. The documented change exports the internal `flagSymbol` so it can be referenced in the `arg` namespace typing.
5.0.1
8/17/2021Release 5.0.1 is described as a patch release that updates dependencies and switches CI to GitHub Actions. The diff shows no clear functional changes to the arg parser itself, but it does include tooling and formatting updates across the repository.
5.0.0
11/17/2020Release 5.0.0 introduces a new error model via `arg.ArgError`, with `.code` values and lowercase error message starts. The codebase also adds new parsing capabilities (including flag counting and positional parsing control) and tightens validation around argument specification keys.
BreakingFeatures