# lunarmodules/Penlight

A set of pure Lua libraries focusing on input data handling (such as reading configuration files), functional programming (such as map, reduce, placeholder expressions,etc), and OS path management.  Much of the functionality is inspired by the Python standard libraries.

Repository: https://github.com/lunarmodules/Penlight
Canonical: https://ross.abutalabs.com/products/penlight
Homepage: https://lunarmodules.github.io/Penlight/
Language: Lua
License: MIT
License Family: permissive
Topics: lua, luajit, penlight, lua-library, luarocks, lua-modules
Last push: 2026-08-15T09:13:03+00:00

## Health v2 (maintenance only)
Score: 76/100 (v2, computed 2026-09-02T17:46:02.011165+00:00)
- activity 97, release rhythm 35, longevity 100
- inputs: {"age_days": 6021, "days_push": 18, "days_rel": null, "gap_med": null, "n_releases_24m": 0}
- flags: no_releases
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 2125, forks 262 (observed 2026-08-28T04:06:16.861882+00:00)

## What it is
Penlight is a set of pure Lua libraries providing generally useful modules for input data handling, functional programming, and OS path management, inspired by the Python standard library. It includes extended string and table operations, iterators, OOP class support, config file reading, argument parsing, and templating.

## Use cases
- read configuration files in lua
- functional programming helpers like map and reduce in lua
- manipulate file paths and directories in lua
- parse command-line arguments for a lua script
- pretty-print lua tables
- extended string operations like split in lua
- list comprehensions and iterator pipelines in lua

## When to choose
- you want a batteries-included standard library extension for Lua
- you need Python-like list, string, and table utilities in Lua
- you want pure-Lua dependencies with no C bindings
- you need config file parsing or usage-text-driven argument parsing in Lua

## When to avoid
- you need high-performance numeric computing or vectorized operations
- you are working outside the Lua ecosystem
- you need async or concurrency primitives, which Penlight does not provide

## Facets
- artifact type: library
- maturity: stable
- function: parser, configuration-management, file-system, templating, cli, data-science
- domain: developer-tools, programming-languages, files
- platform: lua, cross-platform
- tags: lua, functional-programming, standard-library-extension, luarocks, string-manipulation, table-utilities, path-handling, automation

## Member repositories
- lunarmodules/Penlight (main) score 76

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:06:16.861882+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-30T02:52:40.837639+00:00, confidence not recorded.
  - readme: https://github.com/lunarmodules/Penlight (fetched 2026-08-28T04:06:16.861882+00:00, sha a9283680f91b)
  - homepage: https://lunarmodules.github.io/Penlight/ (fetched 2026-08-29T10:32:34.423692+00:00, sha 9be3ded3c9f1)
- Data as of 2026-08-30T08:39:29.467469+00:00.
