# Tyrrrz/CliWrap

Library for interacting with command-line interfaces

Repository: https://github.com/Tyrrrz/CliWrap
Canonical: https://ross.abutalabs.com/products/cliwrap
Homepage: https://nuget.org/packages/CliWrap
Language: C#
License: MIT
License Family: permissive
Topics: command-line, cli, piping, stdout, event-stream, shell, process, pipe-stdout, stderr, pipe-stderr, stdin, pipe-stdin, dotnet, dotnet-core, dotnet-standard
Last push: 2026-08-19T20:13:57+00:00

## Health v2 (maintenance only)
Score: 94/100 (v2, computed 2026-09-03T02:20:16.233290+00:00)
- activity 98, release rhythm 86, longevity 100
- inputs: {"age_days": 3443, "days_push": 14, "days_rel": 14, "gap_med": 41.5, "n_releases_24m": 13}
- flags: none
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 4997, forks 284 (observed 2026-08-28T04:09:04.431085+00:00)

## What it is
CliWrap is a .NET library for interacting with command-line interfaces, providing a fluent, immutable abstraction over System.Diagnostics.Process. It supports launching processes, piping stdin/stdout/stderr, asynchronous execution, and graceful cancellation.

## Use cases
- run external commands from C# code
- pipe stdout and stderr between processes
- execute shell commands asynchronously with cancellation
- capture output of a CLI tool in .NET
- avoid deadlocks when redirecting process streams
- send input to a process's stdin programmatically
- wrap command-line tools in a .NET application

## When to choose
- you're on .NET and need to spawn or script external processes
- you need robust piping, cancellation, and deadlock-free stream handling
- you want a fluent, immutable API instead of raw System.Diagnostics.Process

## When to avoid
- you need to run shell scripts as a full shell environment rather than individual commands
- you're not on a .NET platform
- you need remote or containerized command execution

## Facets
- artifact type: library
- maturity: stable
- function: developer-tools, cli, concurrency, error-handling
- domain: developer-tools, cross-platform
- platform: dotnet, windows, cross-platform
- tags: process-management, piping, stdin-stdout, async, cancellation, fluent-api, nuget, command-line, automation, linux, macos

## Member repositories
- Tyrrrz/CliWrap (main) score 94

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:09:04.431085+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-29T18:17:36.661307+00:00, confidence not recorded.
  - readme: https://github.com/Tyrrrz/CliWrap (fetched 2026-08-28T04:09:04.431085+00:00, sha 70587d0178e6)
  - homepage: https://nuget.org/packages/CliWrap (fetched 2026-08-29T08:58:36.448200+00:00, sha d0a4d07abd27)
  - site_page: https://www.nuget.org/policies/About (fetched 2026-08-29T08:58:36.450863+00:00, sha a113b8a074c9)
- Data as of 2026-08-30T08:39:29.467469+00:00.
