-
Notifications
You must be signed in to change notification settings - Fork 8.1k
Closed
Labels
Issue-BugIssue has been identified as a bug in the productIssue has been identified as a bug in the productResolution-FixedThe issue is fixed.The issue is fixed.WG-Cmdlets-Managementcmdlets in the Microsoft.PowerShell.Management modulecmdlets in the Microsoft.PowerShell.Management module
Description
Steps to reproduce
$sss = New-PSSession server
Copy-Item -Path 'c:\temp\[x]*' -Destination 'c:\temp' -ToSession $sssExpected behavior
Everything that starts with the letter 'x' in the temp folder was copied to server "server".
Actual behavior
PS C:\> Copy-Item -Path 'c:\temp\[x]*' -Destination 'c:\temp' -ToSession $sss
Copy-Item : A parameter cannot be found that matches parameter name 'ToSession'.
At line:1 char:55
+ Copy-Item -Path 'c:\temp\[x]*' -Destination 'c:\temp' -ToSession $sss
+ ~~~~~~~~~~
+ CategoryInfo : InvalidArgument: (:) [Copy-Item], ParameterBindingException
+ FullyQualifiedErrorId : NamedParameterNotFound,Microsoft.PowerShell.Commands.CopyItemCommandEnvironment data
PS C:\> $PSVersionTable
Name Value
---- -----
PSVersion 5.1.16299.251
PSEdition Desktop
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0...}
BuildVersion 10.0.16299.251
CLRVersion 4.0.30319.42000
WSManStackVersion 3.0
PSRemotingProtocolVersion 2.3
SerializationVersion 1.1.0.1
BarnumD and General-Fault
Metadata
Metadata
Assignees
Labels
Issue-BugIssue has been identified as a bug in the productIssue has been identified as a bug in the productResolution-FixedThe issue is fixed.The issue is fixed.WG-Cmdlets-Managementcmdlets in the Microsoft.PowerShell.Management modulecmdlets in the Microsoft.PowerShell.Management module