Which CLI
A PHP symfony/console command similar to the standard which command., (*1)
, (*2)
, (*3)
, (*4)
Requirements
This script requires PHP 5.6, or newer., (*5)
Installation
This package uses composer so you can install it
using composer. Composer can install the command globally using:, (*6)
composer global require nubs/which-cli
This will install it to your $COMPOSER_HOME directory (typically
$HOME/.composer). The which binary will be symlinked to
$COMPOSER_HOME/vendor/bin/which (e.g., $HOME/.composer/vendor/bin/which)., (*7)
Usage
The included which executable works much like the standard which utility. It
takes an arbitrary number of parameters and outputs the path to each of them., (*8)
$ which more vim foo
/bin/more
/usr/bin/vim
foo not found
For windows users, composer will create a which.bat script in
its bin directory that can be executed in much the same way as on a POSIX
system. Alternatively, a which.bat script is included. You may need to add
the bin directory from this repository to your PATH environment variable to
be able to access the command globally., (*9)
License
which-cli is licensed under the MIT license. See LICENSE for the
full license text., (*10)