PS C:\> Get-Help Copy-PSModuleToFolder -Full
Get-Module and copy the ModuleBase to a new Destination\ModuleBase
Copy-PSModuleToFolder [-Name] <String[]> [-Destination] <String> [-RemoveOldVersions] [<CommonParameters>]
Get-Module and copy the ModuleBase to a new Destination\ModuleBase
Name of the PowerShell Module to Copy
Accept pipeline input? true (ByPropertyName)
Accept wildcard characters? true
Destination PSModule directory
Copied Module is a Child of Destination
Accept pipeline input? true (ByPropertyName)
Accept wildcard characters? false
-RemoveOldVersions [<SwitchParameter>]
Removes older Module Versions from the Destination
Accept pipeline input? false
Accept wildcard characters? false
This cmdlet supports the common parameters: Verbose, Debug,
ErrorAction, ErrorVariable, WarningAction, WarningVariable,
OutBuffer, PipelineVariable, and OutVariable. For more information, see
about_CommonParameters (https:/go.microsoft.com/fwlink/?LinkID=113216).
21.1.30.1 Initial Release
21.1.30.2 Added WinPE Parameter
21.1.30.3 Renamed PSModulePath Parameter to Destination, Added RemoveOldVersions
21.1.31.1 Removed WinPE Parameter
21.2.2.1 Renamed to Copy-ModuleToFolder so I don't mess with PowerShellGet
21.2.9.1 Renamed to Copy-PSModuleToFolder to standardize
https://osd.osdeploy.com/module/functions/psmodule/copy-psmoduletofolder