# yargs/yargs

yargs the modern, pirate-themed successor to optimist.

Repository: https://github.com/yargs/yargs
Canonical: https://ross.abutalabs.com/products/yargs
Homepage: https://yargs.js.org/
Language: JavaScript
License: MIT
License Family: permissive
Last push: 2026-08-07T03:15:41+00:00

## Health v2 (maintenance only)
Score: 92/100 (v2, computed 2026-09-02T17:46:02.011165+00:00)
- activity 96, release rhythm 83, longevity 100
- inputs: {"age_days": 4682, "days_push": 26, "days_rel": 38, "gap_med": 37, "n_releases_24m": 4}
- flags: none
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 11515, forks 1042 (observed 2026-08-28T04:10:48.425849+00:00)

## What it is
Yargs is a Node.js library for parsing command-line arguments and building interactive CLI tools. It provides command and option parsing, dynamically generated help menus, and Bash/Zsh completion script generation.

## Use cases
- parse command line arguments in a node script
- build a CLI tool with subcommands like serve --port=5000
- auto-generate a help menu for my command line program
- add bash and zsh tab completion to my CLI
- define positional arguments and options with defaults in node
- replace optimist or minimist with a full-featured arg parser

## When to choose
- you are building a Node.js command-line tool and want argument parsing plus generated help and completions
- you need subcommands, grouped options, validation, and a polished CLI UX with minimal code

## When to avoid
- you need a full interactive terminal UI rather than argument parsing
- you are not working in JavaScript/Node.js
- you only need trivial argv slicing and want zero dependencies

## Facets
- artifact type: library
- maturity: stable
- function: cli, parser, developer-tools
- domain: developer-tools
- platform: cli, cross-platform
- tags: argument-parsing, cli-builder, help-generation, shell-completion, optimist-successor, command-line, automation, nodejs

## Member repositories
- yargs/yargs (main) score 92

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:10:48.425849+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-29T17:15:32.014097+00:00, confidence not recorded.
  - readme: https://github.com/yargs/yargs (fetched 2026-08-28T04:10:48.425849+00:00, sha d8f7da558bb1)
  - homepage: https://yargs.js.org/ (fetched 2026-08-29T08:14:25.193142+00:00, sha 49b7f6c9aacd)
  - site_page: https://yargs.js.org/docs (fetched 2026-08-29T08:14:25.202786+00:00, sha 7747fee9077c)
- Data as of 2026-08-30T08:39:29.467469+00:00.
