# sharkdp/shell-functools

Functional programming tools for the shell

Repository: https://github.com/sharkdp/shell-functools
Canonical: https://ross.abutalabs.com/products/shell-functools
Language: Python
License: MIT
License Family: permissive
Topics: shell, functional-programming, filesystem, string-manipulation, command-line
Last push: 2024-11-22T18:55:20+00:00

## Health v2 (maintenance only)
Score: 23/100 (v2, computed 2026-09-03T02:20:16.233290+00:00)
- activity 0, release rhythm 8, longevity 100
- inputs: {"age_days": 3210, "days_push": 649, "days_rel": null, "gap_med": null, "n_releases_24m": 0}
- flags: none
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 1245, forks 52 (observed 2026-08-28T04:04:06.947120+00:00)

## What it is
A collection of command-line tools that bring functional programming primitives like map, filter, foldl, sort_by, and take_while to the shell. Commands are written in Python, composable via UNIX pipes, and accept a large library of built-in function arguments such as basename, abspath, replace, and is_dir.

## Use cases
- apply a function to every line of shell output
- filter file listings by predicate like is_file or is_dir
- sum or multiply sequences of numbers from the command line
- sort lines by a computed key
- transform filenames with basename, abspath, or string replacements in pipes
- chain higher-order functions over command output

## When to choose
- you want map/filter/fold semantics in shell pipelines without writing awk or Python one-liners
- you frequently manipulate filenames and strings in shell scripts
- you prefer composable UNIX-style command-line tools

## When to avoid
- you need high-performance processing of very large data streams (Python startup overhead per command)
- you want a full functional programming language rather than shell helpers
- your environment cannot install Python packages

## Facets
- artifact type: cli-tool
- maturity: stable
- function: cli, developer-tools, file-system, parser
- domain: developer-tools
- platform: cli, windows, cross-platform
- tags: functional-programming, shell-tools, pipes, map-filter-fold, python, command-line, automation, linux, macos

## Member repositories
- sharkdp/shell-functools (main) score 23

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:04:06.947120+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-30T05:08:11.368159+00:00, confidence not recorded.
  - readme: https://github.com/sharkdp/shell-functools (fetched 2026-08-28T04:04:06.947120+00:00, sha 5f3f02182499)
  - registry_pypi: https://pypi.org/pypi/shell-functools/json (fetched 2026-08-29T12:19:41.034248+00:00, sha 2797d3b17dc3)
- Data as of 2026-08-30T08:39:29.467469+00:00.
