This pull request fixes an issue with the Install-ModuleFast function where it doesn't install modules in the specified destination if the same module is already installed in a different location on the system.
To address this issue, I have added a new parameter -DestinationOnly to the Install-ModuleFast function. When this parameter is specified, the function will only consider the specified destination and not any other paths currently in the PSModulePath. This is useful for scenarios where you want to ensure that the modules are installed in a specific location, such as in a CI environment.
I have also made changes to the Get-ModuleFastPlan and Find-LocalModule functions to support the new -DestinationOnly parameter.
Fixes #45
This pull request fixes an issue with the
Install-ModuleFast
function where it doesn't install modules in the specified destination if the same module is already installed in a different location on the system.To address this issue, I have added a new parameter
-DestinationOnly
to theInstall-ModuleFast
function. When this parameter is specified, the function will only consider the specified destination and not any other paths currently in thePSModulePath
. This is useful for scenarios where you want to ensure that the modules are installed in a specific location, such as in a CI environment.I have also made changes to the
Get-ModuleFastPlan
andFind-LocalModule
functions to support the new-DestinationOnly
parameter.