shebang-regex provides a JavaScript regular expression for matching a Unix shebang line (the #! prefix at the start of a script). It includes easy usage to test a string and extract the interpreter path from a line like #!/usr/bin/env node.
Project status
- Maintenance status: The source appears not actively maintained. The most recent update upstream is 2021-08-13, which is well over two years ago relative to 2026-06-09.
- Update cadence: Updates are infrequent and spaced far apart, with notable version jumps at v2.0.0 (2015), v3.0.0 (2019), and v4.0.0 (2021). No newer updates are shown after v4.0.0.
AI summary generated
Recent updates
v4.0.0
Release v4.0.0 converts shebang-regex to a pure ESM package and updates its Node.js engine requirements. The diff also shows changes to how the RegExp is exported (default export) along with TypeScript declaration updates and various tooling/dependency and repository config updates.
Breakingv3.0.0
v3.0.0 introduces a new TypeScript definition file for the package. The main breaking change is a Node.js runtime requirement update, which may affect older environments.
BreakingFeaturesv2.0.0
Release v2.0.0 was published on 2015-12-04, but the publisher did not include any release notes. Because no change descriptions are provided, developers should review the diff between the v2.0.0 tag and the previous version to identify any API, behavior, or configuration changes.