Skip to content

paulmelnikow/hasbin-cli

Repository files navigation

hasbin-cli

version license build code style

From the command line, check whether a binary exists in the PATH environment variable.

Usage

Make sure that one or more programs is installed.

hasbin foreman heroku || echo 'Foreman and heroku are required!' && exit 1
hasbin --all foreman heroku || echo 'Foreman and heroku are required!' && exit 1

Make sure that at least one program is installed.

hasbin --some brew apt-get || echo 'Please install a package manager.' && exit 1

Return the name of the first program that is installed.

echo 'Your package manager is:' && hasbin --first brew apt-get

Installation

npm install hasbin-cli

Contribute

Pull requests welcome!

Support

If you are having issues, please let me know.

License

The project is licensed under the MIT license.

About

From the command line, check whether a binary exists in the PATH environment variable

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published