shebang-command
DefinitelyTyped icon, indicating that this package has TypeScript declarations provided by the separate @types/shebang-command package

2.0.0 • Public • Published

shebang-command Build Status

Get the command from a shebang

Install

$ npm install shebang-command

Usage

const shebangCommand = require('shebang-command');
 
shebangCommand('#!/usr/bin/env node');
//=> 'node'
 
shebangCommand('#!/bin/bash');
//=> 'bash'

API

shebangCommand(string)

string

Type: string

String containing a shebang.

Package Sidebar

Install

npm i shebang-command

Weekly Downloads

62,038,002

Version

2.0.0

License

MIT

Unpacked Size

2.56 kB

Total Files

4

Last publish

Collaborators

  • kevva