Go to repository

Function getBin

Get the path to one of the bin scripts exported by a package. If the bin name is different from the package name, it should be given, if not given, the name of the binary is assumed to be the same of that of the package.

Parameters

  • projectRootPath: string

    The currently identified project's root path.

  • packageManagerDefinition: PackageManagerDefinition

    The definition to all available package managers.

  • packageName: string

    The name of the package holding the binary.

  • Optional
    binName: string

    The name of the binary that it's intended to be retrieved.

Returns undefined | ExecutableScriptDefinition

The information for the binary execution, or undefined if no binary was found.